May
24

R important things

R has no block comment, but you can still do the following things:

  • In RStudio: Ctrl+Shift+C
  • if(false){xxx} block

 

python to R

df.tail() -> tail(df)

dropna(df) ->na.omit(df) / df[complete.cases(df),]

df.describe() -> summary(df), library(psych): describe(df)

df.shape -> dim(df)

Written by connygy. Posted in R

Trackback from your site.

Leave a comment