Question: "header" function in R
0
gravatar for morteza.hadizade
11 months ago by
Physiology Research Center, Institute of Basic and Clinical Physiology Sciences, Kerman University of Medical Sciences, Kerman, Iran
morteza.hadizade10 wrote:

Hello everyone, How to add the "header" function to a dataset in R? for example, this command enters in the R, but I encounter the following error in the software.

res<- read.ftable("C:/R Database/Volcano/results.txt", header= TRUE)

Error in read.ftable("C:/R Database/Volcano/results.txt", header = TRUE) : unused argument (header = TRUE)

R software error • 500 views
ADD COMMENTlink modified 11 months ago by h.mon24k • written 11 months ago by morteza.hadizade10

instead use

res <- read.table("C:/R Database/Volcano/results.txt", header= TRUE)

ADD REPLYlink modified 11 months ago • written 11 months ago by arta540
read.csv(""C:/R Database/Volcano/results.txt", header = T, sep = "\t", stringsAsFactors = F)

change sep argument if separator is not tab, but some thing else.

ADD REPLYlink written 11 months ago by cpad011211k
0
gravatar for h.mon
11 months ago by
h.mon24k
Brazil
h.mon24k wrote:

header= is not a function, it is an argument to a function. This argument is not used for read.ftable(), hence the error.

See ?read.ftable

ADD COMMENTlink modified 11 months ago • written 11 months ago by h.mon24k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1407 users visited in the last hour