Re: How to enter cross-sectional time-series data into SPSS for correlation

Posted by PRogman on
URL: http://spssx-discussion.165.s1.nabble.com/How-to-enter-cross-sectional-time-series-data-into-SPSS-for-correlation-tp5726681p5726956.html

TotalCount differs because AGGREGATE sums up the values of topic_count; if the value is 1 it is actually a count, if it is 2 the count gets doubled, if topic_count is 22 it adds extra 20 counts (ie 10 cases). The RECODE command sets anything but 1 or 2 to -1 which is then declared missing.
totalCount gives Twitter and Spon, 317+26=343 cases.

If you try
FREQUENCIES VARIABLES=Day 
  /STATISTICS=RANGE MINIMUM MAXIMUM MODE .

CROSSTABS
  /TABLES=Outlet BY Time.
you will find that 'day' is a constant (=1) and that Twitter=T1 and Spon=T2 .
The SPLIT FILE runs CORRELATION on every 'content' which is just 1 line each...
You might need to consult your local statistician.
You could try this:
DATASET ACTIVATE copydata.
SORT CASES  BY content outlet.
SPLIT FILE LAYERED BY content.
CROSSTABS
  /TABLES=Outlet BY topic_count
  /FORMAT=AVALUE TABLES
  /STATISTICS=CORR 
  /CELLS=COUNT
  /COUNT ROUND CELL.
SPLIT FILE OFF.

/PR