cutoffvalue: Importing your raw data
Lea R Medeiros
2025-08-21
ImportRawData.Rmd
Importing your raw dataset
This vignette covers suggested ways to import your data file to be used in the analyses and graph and assumes you have installed the cutoffvalue package and loaded the necessary packages (see the Getting Started vignette for more information). If you need help on other topics, please see either the main vignette (Help) or refer to the vignette for another topic.
Import your own dataset any way you prefer. I find that the easiest way to import data is to use the “Import Dataset” function built into R Studio, but you can also use code. The imported data must then be converted into a list of numeric values. An example of code that should work (after you update certain parts to be specific to your dataset) is included below.
# yourrawdata <- read_excel("/path/to/your/excel/data", col_names = TRUE) # Imports the data as a dataframe with first row as column names
# yourrawdata <- as.numeric(yourrawdata$columnname) # converts the specified column to a numeric list of values
The package also includes a dataset for use as an example - this object is accessible as “cutoffvalue:::exampledata” and will be used in the examples.
Each function in this package uses the provided dataset (whether it’s
the example dataset or one you provided) and cleans it up (via the
cleandata
function) to remove any blank cells. This
function then provides a list of objects: the data
(mydata$data
), the maximum value
(mydata$upper
), and the minimum value
(mydata$lower
), all of which are then used in subsequent
calculations.