Re: [R] a simple question of importing data

From: Jorge Ivan Velez <jorgeivanvelez_at_gmail.com>
Date: Thu, 24 Apr 2008 15:59:14 -0400

Try also,

setwd("C:\\")
yourdata=read.table("tzmile.txt",header=TRUE) attach(yourdata)
yourdata[1:10,]
 warcode date weeklyrt

1    30001 16-Dec-05  -0.0043
2    30001 23-Dec-05   0.1313
3    30001 30-Dec-05  -0.0844
4    30001  6-Jan-06   0.0097
5    30001 13-Jan-06  -0.1009
6    30001 20-Jan-06  -0.0450
7    30001 25-Jan-06  -0.1700
8    30001 10-Feb-06   0.3060
9    30001 17-Feb-06  -0.0721
10   30001 24-Feb-06   0.2260

HTH, Jorge

On Thu, Apr 24, 2008 at 3:53 PM, Charles Danko <dankoc_at_gmail.com> wrote:

> try:
> var <- read.table("weekly.txt", sep="\t", header=TRUE)
>
> Charles
>
> On Thu, Apr 24, 2008 at 3:29 PM, tzsmile <rz2171_at_yahoo.com> wrote:
> >
> > i just want to read data from Excel and i copied it and pasted into a
> txt
> > file.
> > then i want to use "read.table" to read it. but however i tried, it
> doesn't
> > work.
> > can someone help me?
> > data is attached.
> > thanks http://www.nabble.com/file/p16851853/weekly.txt weekly.txt
> > --
> > View this message in context:
> http://www.nabble.com/a-simple-question-of-importing-data-tp16851853p16851853.html
> > Sent from the R help mailing list archive at Nabble.com.
> >
> > ______________________________________________
> > R-help_at_r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> > and provide commented, minimal, self-contained, reproducible code.
> >
>
> ______________________________________________
> R-help_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

        [[alternative HTML version deleted]]



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 24 Apr 2008 - 20:25:41 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 24 Apr 2008 - 20:31:06 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive