Simple:

> install.packages('xlsx')
> setwd('C://) (Define directory with your file)
> data <- read.xlsx('file.xlsx', 1) (Read the first spreed sheet)

On Wed, Nov 14, 2012 at 3:25 PM, jim holtman <jholtman@gmail.com> wrote:

> Also checkout the XLConnect package since it can read/write EXCEL
> files directly so that you do not have to go through the step of
> creating a CSV file.  Really nice when you want to create an Excel
> file with multiple worksheets containing different phases of your
> analysis.
>
> On Wed, Nov 14, 2012 at 8:45 AM, shwetank <shwetank@iasri.res.in> wrote:
> > The simplest way, in my opinion is:
> >>save .xls file as .csv in ms excel "save as" option. csv means comma
> > delimited.
> >>now type following command on R console;
> >         >mydata<-read.csv(file.choose())
> >              this will open a dialog box will open and select your .csv
> > file.
> >         now the data will be saved as "mydata" is actually a data frame.
> >
> > Enjoy,
> > regards.
> >
> >
> >
> >
> > --
> > View this message in context:
> http://r.789695.n4.nabble.com/how-to-import-data-from-excel-to-R-tp966629p4649487.html
> > Sent from the R help mailing list archive at Nabble.com.
> >
> > ______________________________________________
> > R-help@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.
>
>
>
> --
> Jim Holtman
> Data Munger Guru
>
> What is the problem that you are trying to solve?
> Tell me what you want to do, not how you want to do it.
>
> ______________________________________________
> R-help@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.
>



-- 
Att,

Flávio Barros

	[[alternative HTML version deleted]]


