Re: [R] How to import data from a text file in R

2012-11-25 Thread John Kane
Save the file as a csv file and try something like this: mydata <- read.csv(".csv", header = FALSE) John Kane Kingston ON Canada > -Original Message- > From: claudio.dilor...@carloalberto.org > Sent: Sun, 25 Nov 2012 03:29:42 -0800 (PST) > To: r-help@r-project.org > Subject:

Re: [R] How to import data from a text file in R

2012-11-25 Thread Jim Holtman
read the 'intro to R' again and then ?scan ?read.table Sent from my iPad On Nov 25, 2012, at 6:29, dilo88 wrote: > Hi, > > I'd like to import a 154x1 vector of a stock monthly returns from a text (or > excel spreadsheet) into R. I need to work on this vector by calculating > mean, variance an