Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

write_spss

Write data to other statistical software packages


Description

These functions write the content of a data frame to an SPSS, SAS or Stata-file.

Usage

write_spss(x, path, drop.na = FALSE, compress = FALSE)

write_stata(x, path, drop.na = FALSE, version = 14)

write_sas(x, path, drop.na = FALSE)

Arguments

x

A data frame that should be saved as file.

path

File path of the output file.

drop.na

Logical, if TRUE, tagged NA values with value labels will be converted to regular NA's. Else, tagged NA values will be replaced with their value labels. See 'Examples' and get_na.

compress

Logical, if TRUE and a SPSS-file should be created, saves x in zsav (i.e. compressed SPSS) format.

version

File version to use. Supports versions 8-14.


sjlabelled

Labelled Data Utility Functions

v1.1.8
GPL-3
Authors
Daniel Lüdecke [aut, cre] (<https://orcid.org/0000-0002-8895-3206>), avid Ranzolin [ctb], Jonathan De Troye [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.