Learn R Programming

strum (version 0.6.2)

createStrumData: Create strumData Object

Description

A function to create strumData object.

Usage

createStrumData(inData, dType, ibdFileName=NULL, fileType="SAGE")

Arguments

inData
Object of class data.frame containing input data.
dType
Character stating the type of input data, "Pedigree" or "RawData"
ibdFileName
Character stating the name of ibd file to import.
fileType
Character stating the type of ibd file, the deafult value is "SAGE".

Value

Returns an object of class strumData.

Details

This function is used to create a strumData class object for strum analysis. The value of inData has to be a data.frame. The allowed values for dType is either "Pedigree" or "RawData". Note that, if dType="Pedigree", the data must be a data.frame with 4 required fields - family, id, father, mother.

The ibd information for the family data can be imported by specifying the name of ibd file into ibdFileName. Currently, the ibd file generated by the program GENIBD in S.A.G.E. package is supported.

See Also

strumData, simulateStrumData

Examples

Run this code
## Not run: 
# # Create a strumData object with different type of input data.
# # - dF is a data.frame containing input data.
# #-------------------------------------------------------------
# rawStrumData = createStrumData(dF, "RawData") 
# pedStrumData = createStrumData(dF, "Pedigree")
# pedStrumDataIBD = createStrumData(dF, "Pedigree", ibdFileName="ch20.ibd")
# ## End(Not run)

Run the code above in your browser using DataLab