가중치를 적용한 빈도표를 만들고 싶으면~
https://stackoverflow.com/questions/18585977/frequency-tables-with-weighted-data-in-r
Frequency tables with weighted data in R
I need to calculate the frequency of individuals by age and marital status so normally I'd use: table(age, marital_status) However each individual has a different weight after the sampling of...
stackoverflow.com
특히 , expss 패키지의 fre 함수를 이용하면, 퍼센티지까지 구해주므로 손쉽다.
그런데 panel data 처럼 가중치를 적용한 교차표를 만들고 싶을 때도 있다.
이런 경우에는
https://stackoverflow.com/questions/60558479/doing-row-column-percents-with-survey-data-in-r
Doing row/column percents with survey data in R?
I am analyzing some survey data in R. Due to the sample design, all analysis has to be done with the "survey" package that can take the sample structure into account, which means I can't just get w...
stackoverflow.com
survey 패키지를 사용할 수 있다.
'R' 카테고리의 다른 글
패키지 저장 폴더 설정 (0) | 2024.03.02 |
---|---|
lattice 패키지로 그래프를 그릴 때의 팁들 (0) | 2024.01.08 |
plyr 패키지 설치 에러 (0) | 2023.12.23 |
Rstudio에서 copilot 사용하기 (0) | 2023.12.02 |
R에서 한글 사용하기/한글 폰트 불러오기 (1) | 2023.11.25 |