Saturday 29 August 2020

dataframe in R

dataframe:It is displayed in tabular format,it has proper var name and it is mix up data(heterogeneous)

Example:
Name  Age  Address
  jill        45    boston
nick      32    london
sam      25   india

Address:character
Name:Character
Age:Numeric

Note: R is case sensitive

#dataframe:displayed in tabular format, proper variable name and heterogeneous

Name<-c("jill","nick","sam")
Age<-c(45,32,25)
Address<-c("boston","london","india")
x<-data.frame(Name,Age,Address)
x
str(x)

1 comment:

  1. You don't realize how quickly technology is changing. Data science is highly technical and is therefore in high demand. A career in data science will open up many lucrative job opportunities. So, if you have been wanting to start your career in Data Science, now is the best time to enroll in a data science program with one of the best data science training institute in noida.

    ReplyDelete

apply function in R

1) apply function: It takes 3 arguments matrix,margin and function.. Example: m<-matrix(c(1,2,3,4),nrow=2,ncol=2) m #1 indicates it is ap...