trouble with contingency table in R -


i looked everywhere did not find answer question. having trouble makig contingency table. have data many columns, let 1, 2 , 3. in first column there let 100 different values, in second 20 , third column has 2 possible values: 0 , 1. first take data value 1 in column 3 (data<-data[column3==1,]). have around 20 different values in 1. column , 5 in 2. column. when contingency table size 100x20, not 20x5, , contains lot of zeros (they correspond combination of column1 , column2 has value 0 in column3). greatful every kind of help, thanks.

just use

table()

function data after doing

data<-data[column3==1,])

it might helpfull


Comments

Popular posts from this blog

java - Run spring boot application error: Cannot instantiate interface org.springframework.context.ApplicationListener -

reactjs - React router and this.props.children - how to pass state to this.props.children -

Excel VBA "Microsoft Windows Common Controls 6.0 (SP6)" Location Changes -