filterDataSet: Filter Data set

Description Usage Arguments Value Author(s) Examples

View source: R/filterDataSet.R

Description

filterDataSet selects relevants columns from a data set and remove species if the name does not exist in the global database.

Usage

1
2
filterDataSet(data, endogene_lipid_db, ISTD_lipid_db,
  userSpecifiedColnames = NULL)

Arguments

data

data formatted by the use of the mergeDataSet function from LipidQ.

endogene_lipid_db

the endogene lipid database

ISTD_lipid_db

the ISTD lipid database

userSpecifiedColnames

the column names template file containing user specified column names for the input data.

Value

a filtered data set

Author(s)

André Vidas Olsen

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
# load endo & ISTD databases as well as user specified column names file.
endogene_lipid_db <- read.table(system.file("extdata/dataTables/checks",
 "endogene_lipid_db.csv", package = "lipidQ"), stringsAsFactors = FALSE,
 header = TRUE, sep = ",")

ISTD_lipid_db <- read.table(system.file("extdata/dataTables/checks",
 "ISTD_lipid_db.csv", package = "lipidQ"), stringsAsFactors = FALSE,
 header = TRUE, sep = ",")

userSpecifiedColnames <- read.table(system.file("extdata/LipidQ_DataBase",
 "userSpecifiedColnames.csv", package = "lipidQ"),
 stringsAsFactors = FALSE, header = TRUE, sep = ",")

# load is sorted mergedDataSet made by using the mergeDataSets() function
mergedDataSetsIsSorted <- read.table(system.file("extdata/dataTables/checks",
 "mergedDataSets.csv", package = "lipidQ"),
 stringsAsFactors = FALSE, header = TRUE, sep = ",")

# filter the data set
filteredDatasets <- filterDataSet(data = mergedDataSetsIsSorted,
 endogene_lipid_db = endogene_lipid_db, ISTD_lipid_db = ISTD_lipid_db,
 userSpecifiedColnames = userSpecifiedColnames)

ELELAB/lipidQ documentation built on Feb. 24, 2020, 12:54 a.m.