# NOT RUN {
#data simulation of 10 person
set.seed(2020)
n <- 10
matsim <- matrix(0, n, 218)
datsim <- as.data.frame(matsim)
datsim$V1 <- LETTERS[1:n]
#calory for boiled rice
datsim$V2 <- rnorm(n, 200, 50)
#calory for boiled egg
datsim$V73 <- rnorm(n, 60, 5)
#calory for fresh milk
datsim$V79 <- rnorm(n, 100, 10)
#calory for tomato
datsim$V93 <- rnorm(n, 19, 2)
#caloty for pineapple
datsim$V134 <- rnorm(n, 20, 2)
kalori(datsim)
# }
Run the code above in your browser using DataLab