1. B

    Syntax error: Error in sqliteExecStatement

    Hi guys, I have the following problem: I am trying to do a multinomial logistic regression on a very large dataset. My dataset has 6 columns (5 independent variables and 1 dependent variable) and 176,483 rows (observations). The function in R which does exactly what I need is...
  2. K

    Syntax Distribute Days across years

    Hi, I need to create variables that splits out a length of stay across years and enters the number of days in each of those years into separate year variables. For example, I have a length of stay for a case of 8.02 years. CaseID StartDate EndDate 222 12/23/1988 01/01/1997...
  3. P

    Within subjects ANOVA pairwise comparisons - is there a way to use TUKEY HSD?

    Hi I am running a 3 x 4 repeated measures within subjects ANOVA - the options SPSS gives me for the pairwise adjustments is LSD, Bonferonni and Sidak. However, I need to run post hoc using TUKEY HSD. I tried changing bonferroni for TUKEY in the syntax but to no avail. Just to emphasise, I am...
  4. S

    Syntax results in incorrect variable name - not defined

    Thanks in advance for your assistance. I have been using the following syntax to calculate Chi Square stats (for a large number of groups). Somewhere I have corrupted the code and cannot get it to run due to a variable not defined error (included below). A second error message regarding...
  5. J

    Using Median and Standard Deviation in syntax

    Hi, I'm quite new to SPSS and am looking to code my data records by whether or not they are within 1 standard deviation of the median for that variable. So far I have been doing this for each variable: DO IF (HumanIL21Normalised GE -1.6336 AND HumanIL21Normalised LE 0.3664). COMPUTE...
  6. J

    string value too long

    I am recoding a lot of string variables using syntax. Many of the values (answers people have given to questions) are too long according to spss- it says I need to restrict the line length to 251bytes. but if i split it into 2 lines on the syntax then it doesn't recognise that this is one string...
  7. J

    carrying over values from one variable if missing in another

    I want to carry over (or copy) values from one variable to another, but only if they are missing values in the second variable. Could you tell me what syntax I should use? Is it if var2=99 var2=var1 ?? Thanks a lot
  8. A

    Confusion with writing command for meta-analysis in STATA

    I am a beginner in STATA and do not understand how to write syntax for the meta-analysis command using the variables in my research study. Any help would be so greatly appreciated! My study: I am trying to use meta-analysis to investigate how several different variables impact prevalence...
  9. J

    GET DATA loop through folder

    Hi I need to run the same syntax over some files. They are in the folder named DBase. I mean, there is a db01.sav and over it run the syntax, then do the same for db02.sav and so on. How do i make it? How run the process only listing one time the files i'm interested? Thanks for your time...
  10. V

    hierarchical regression with different DV for each block?

    Greetings. I'm trying to figure out how to do a hierarchical regression whereby the DV regressed on block 1 becomes the IV in block 2, which then has a different DV. That DV then becomes the IV in block 3, at which point the final DV is in place. It'd look something like this: Block 1...
  11. M

    How to write more efficient syntax with Logical Operator commands & string variables?

    Is there a shorter/more efficient syntax for Logical Operator Commands (AND, OR) with string variables? I always end up writing it out over and over again, which is very time consuming. For example, below is there a way that I can only write INCOMESOURCE one time? COMPUTE EMPLOYED=0. IF...
  12. L

    SELECT IF command in SPSS syntax

    Dear all, I am having some difficulties with the SELECT IF command. Please find attached screenshots of my syntax: Syntax: Dataset:
  13. A

    Comparing values of subsequent cases (syntax)

    Hi! I'm stuck with a seemingly simple problem (comparing values One variable - Multiple cases). Please help! This is what I want to do: I have records for a variable for different participants for several subsequent months, that is there is more than one case for each participant (number of...
  14. T

    Help with finding a command in syntax for a very large dataset

    Hello! I am working with a very large medicationprescription dataset (over 50 000 participants). In addition, every participant have on average 10 medications listed vertically, so that each participant occupy many cases vertically. I have to merge one file with the prescription data with...
  15. R

    Importing from Excel: SAS Newbie

    I have an Excel table. In SAS 9.2, I can use File > Import Data to bring that table into the SAS Explorer pane: contents of Work now includes that file. If I double-click on it, I get a VIEWTABLE pane showing the data. I am under the impression that it exists as a temporary file that I...
  16. Rmaxwel2

    Syntax for a Non-Parametric (Friedman/Rpt. Measures), Nested ANOVA?

    Hi, all, how sweet it is to discover a stats forum w/ helpful users like yourselves. :D Here's my first (but certainly not last) question for you all: I have a 2X2 IV/repeated measures DV design w/ nested small groups (random effect variable; see Anderson & Ager, 1978). My measures are...
  17. E

    LISREL syntax error

    Hi all, I'm looking for help with my syntax testing invariance of means and intercepts across two groups. The data was teacher-supplied, so my problem is DEFINITELY somewhere in my syntax, which is posted below. I keep getting errors saying my phi matrix is not positive definite, and I have...
  18. T

    Delete Variable Syntax

    Hi all, Using syntax, is there way to delete all variables in a dataset, listing only those you want to keep? Example: Variables: A/B/C/D/E Standard Syntax (keeping A/B/C) DELETE VARIABLES D E. Syntax to keep A/B/C by listing A/B/C??? Thanks very much.
  19. M

    Combinatorics in Stata 12

    Hi, I am trying to generate new variables in a stata dataset which includes all pairwise and triplets combinations of a count of 14 conditions. The conditions are listed as values in one variable 'chrondis' 1 to 14. chrondis | Freq. Percent Cum...
  20. L

    really complicated: how to cumulate one variable in function of the CHANGE in another

    Hello everybody! I got a SPSS file with the variables "user-id" "date" and than certain information about his consumer behaviour and payments for this particular month. I now want to calculate -for example- the overall amount spent by every customer. The user-ids are not consecutive...