Assignment -1
> z1<-c(12:20)
> dim(z1)<-c(3,3)
> z1
> z2<-c(11:19)
> dim(z2)<-c(3,3)
> z2
> x<-z1[,3]
> x
[1] 18 19 20
> y<-z2[,1]
> y
[1] 11 12 13
> z3<-cbind(x,y)
> z3

Assignment-2
Multiply matrix
> mul<-z1%*%z2
> mul
Assignment-3
Historical data of indices from NSE site from Dec 1 2012 to Dec 31 2012. Find Regression and Residuals.
> reg3<-lm(High~Open,data=nse2)
> reg3
Call:
lm(formula = High ~ Open, data = nse2)
Coefficients:
(Intercept) Open
1578.3358 0.7355
> high<-nse2[,3]
> open<-nse2[,2]
> reg3<-lm(high~open)
> reg3
Call:
lm(formula = high ~ open)
Coefficients:
(Intercept) open
1578.3358 0.7355

Assignment-4
Normal distribution data and plot it.
> z1<-c(12:20)
> dim(z1)<-c(3,3)
> z1
> z2<-c(11:19)
> dim(z2)<-c(3,3)
> z2
> x<-z1[,3]
> x
[1] 18 19 20
> y<-z2[,1]
> y
[1] 11 12 13
> z3<-cbind(x,y)
> z3
Assignment-2
Multiply matrix
> mul<-z1%*%z2
> mul
Assignment-3
Historical data of indices from NSE site from Dec 1 2012 to Dec 31 2012. Find Regression and Residuals.
> reg3<-lm(High~Open,data=nse2)
> reg3
Call:
lm(formula = High ~ Open, data = nse2)
Coefficients:
(Intercept) Open
1578.3358 0.7355
> high<-nse2[,3]
> open<-nse2[,2]
> reg3<-lm(high~open)
> reg3
Call:
lm(formula = high ~ open)
Coefficients:
(Intercept) open
1578.3358 0.7355
Assignment-4
Normal distribution data and plot it.
x=seq(70,130,length=200)
y=dnorm(x,mean=100,sd=10)
plot(x,y)

No comments:
Post a Comment