Hello.
I am reading a SPSS file using this command:
base <- read_sav(here("C:/Users/Base.sav"))
If I want to see all values of a specific variable x with this command
base$x
I obtain this (I am showing only the last row of data):
[985] 3 6 3 5 6 5 5 6 3 6 6 6 4 4 5 6
[ reached getOption("max.print") -- omitted 1712 entries ]
Labels:
value label
1 Agro
2 Otros
3 Manu
4 Const
5 Comer
6 Servi
99 Igno
From this output it can be seen that the variable read the labels and levels from the original SPSS file. However, if I want to see the levels associated to the values this is what I get:
levels(base$x)
NULL
How can I associate the levels that are supposedly related to each value of variable x?
Thank you for your help.