import: Import Function

View source: R/import.R

importR Documentation

Import Function

Description

import reads in a dataframe from a file.

Usage

import(file, ...)

Arguments

file

a character string of the file.

...

Additional arguments passed to the underlying import functions. For example, this can control column classes for delimited file types, or control the use of haven for Stata and SPSS or readxl for Excel (.xlsx) format.

Details

This function imports a data frame from a data file using a filename, or prompt the user to choose a file without the need to provide a filename.

Value

return a dataframe.

Author(s)

Ahmed Aldarmaki aaldarmaki@wesleyan.edu

See Also

read_sas, read_stata, read_spss, read_excel, vroom.

Examples

## Not run: df <- import("datasetexample.xlsx")
## Not run: df <- import("datasetexample.xlsx", col_names=TRUE)

aaldarmaki9/dsproject documentation built on July 16, 2025, 10:13 p.m.