0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

【R】データフレームの出力

Last updated at Posted at 2019-09-03

備忘録的なメモです。

データフレームを出力する方法。

データフレームは、Rの標準データの、

InsectSprays

です。

DF <- InsectSprays

出力には**write.table()**関数を使います。

write.table(DF, "InsectSprays.csv", append = F,sep = ",", row.names = F, quote = F)

append:Fだと上書き、Tだと追記
sep:","で文字列を区切る
row.names:行名を加えるかどうか
col.names:列名を加えるかどうか
quote:Tだと二重引用符""で囲まれる

保存場所は、ディレクトリで指定。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?