This function takes a file object (from read.table), removes the # symbol, sets the 5th row as the column names of the data.frame and removes the rows containing the priority, data type and column name. use read.table as follows: read.table(file, sep='\t', colClasses = 'character', comment.char = '')

cBioPortalToDataFrame(data)

Arguments

data

The data.frame of a cBioPortal sample/patient data file

Value

data.frame

Examples

df <- data.frame(
        V1=c("#attr_1", "#attribute 1", "#STRING", "#1", "ATTRIBUTE_1", "value_1"), 
        V2=c("attr_2", "attribute 2", "STRING", "1", "ATTRIBUTE_2", "value_2")
    )
cbpManager:::cBioPortalToDataFrame(df)
#>   ATTRIBUTE_1 ATTRIBUTE_2
#> 1      attr_1      attr_2
#> 2 attribute 1 attribute 2
#> 3      STRING      STRING
#> 4     value_1     value_2