OstfriesenBI / PredmiRNA

A set of scripts and tools to train a classifier for pre-miRNA Recognition
1 stars 0 forks source link

R Script: Join csv files #5

Closed Finesim97 closed 5 years ago

Finesim97 commented 5 years ago

The feature computation should be able to be run in parallel. Every program should generate a csv file, which looks like this:

"comment","feature1here"
"A1",100
"B2",200
"comment","feature2here"
"B2",0.5
"A1",0.25
"comment","sequence","realmiRNA"
"A1","ZZZZZ",0
"B2","XXXX",1

These files then need to be combined: Output:

"comment","sequence","realmiRNA", "feature1here","feature2here"
"A1","ZZZZZ",0,100,0.25
"B2","XXXX",1,200,0.5

R provides easy functions to join two data frames: https://www.statmethods.net/management/merging.html

The function in the script should be able to read any number of csv files and combine them. combinecsvfiles <- function(in_files, out_path, real) {

code here

}

fi6015 commented 5 years ago

done