Learn R Programming

genvar (version 0.0.1.4)

use: uses a dataset, marking it as the active dataset

Description

uses a dataset, marking it as the active dataset

Usage

use(x, clear = FALSE, type = NULL, ...)

Arguments

x

usually either a data.frame or a csv/dta filename to be imported. An R function which returns a data.frame can also be specified.

clear

if TRUE, erase current data if it already exists (default: FALSE).

type

either "csv" or "dta" for loading csv or dta data set

...

other options to pass to read.csv in case x is a csv file or to read.dta or read.dta13 depending on the type of file being loaded

Value

returns NULL invisibly

Examples

Run this code
# NOT RUN {
library(plm)
data(Produc)
use(Produc, clear=TRUE)
listif()
dropvar(".*")
# }

Run the code above in your browser using DataLab