How can you import data in R?

devquora
devquora

Posted On: Feb 22, 2018

 

There are several ways to import data in R. You can use R commander to import data in R.

  • Excel file- If the sample data is in excel format, function read.xls is used from the data package. It returns a data frame. Alternatively, loadWorkbook can also be used to read the entire workbook.
  • Minitab file- if the data file is in Minitab format, it can be opened using the function read.mtb. It returns a list of components in the Minitab worksheet.
  • SPSS file- the data files in SPSS formats can be opened using the function read.spss. It returns a list of components.
  • CSV file- Each cell inside the CSV data file is separated by a special character such as a comma.

    Related Questions

    Please Login or Register to leave a response.

    Related Questions

    R Programming Interview Questions

    What is R Programming?

    R is a programming language and a software environment meant for statistical analysis and creating graphs. It is used b..

    R Programming Interview Questions

    Enlist some of the functions that R provides?

    The functions that R provides areMean- it is calculated by taking the sum of the values and dividing it by a number o..

    R Programming Interview Questions

    What are the different data structures in R?

    Data structure is a form of organizing and storing data. It is imperative to have a strong understanding of various dat..