October 2017
Beginner to intermediate
572 pages
26h 1m
English
Perform the following steps in R:
>install.packages("TraMineR")> library(TraMineR)> data("mvad")> head(mvad)>alphabet = seqstatl(mvad[,17:86])Output [1] "employment" "FE" "HE" "joblessness" "school" "training" > fulllabel<- c("employment", "further education", "higher education","joblessness", "school", "training") > shortlabel<- c("EM", "FE", "HE", "JL", "SC", "TR") > seq_mvad<- seqdef(mvad[, 17:86], alphabet = alphabet, states = shortlabel, labels = fulllabel, weights = mvad$weight, xtstep = 6) Output [>] state coding: [alphabet] [label] [long label] 1 employment EM employment 2 FEFE further education 3 HEHE higher education 4 joblessness JL joblessness 5 school SC school 6 training TR training [>] sum of weights: 711.57 ...Read now
Unlock full access