You dont need to continue here to old content

From InterSciWiki
Jump to: navigation, search

||Trestles queue: If you run Trestles (20 minutes) make sure each variable has >57 cases which v673 does not. Screen shot 2013-06-25 at 2.58.20 PM.png You may want to print this page in horizontal orientation at (Mac: scale 90) to save a paper copy. You will need to find our variables at one of the SCCS, EA, LRB, or WNAI R codebooks to find your variables or the original SCCS Codebook that has topical and Levinson CCR Encyclopedia indices. The topical index is very useful in finding variables for study.

Screen Shot 2013-06-18 at 1.18.13 PM.png
This Galaxy page has three things wrong and one right: (1) Model 39-40 activates EAF1c at the UCI Virtual Machine: but the "'Shaman" variable (sccsA$v2003==1)*1 was not added to the dataset until DEf2 LOCAL DEF2)' was implemented, as used in model 35-36. (2) Clicking 36 would give the list of societies; 35 has been clicked and shows the Model and its variables. There we see the dependent variable name "Shaman" in the white box: when the diskette image is clicked, a Galaxy....csv is saved to your laptop (in a Mac it ""flies"" to the upper right of your screen which will acquire a down-arrow that, when clicked, will hold your downloads, here: Galaxy.csv files. These *.csv files may be saved to *.xls format that may be edited. (3) The error here is that it is (sccsA$v2013==1)*1 that indexes the Shamanic societies in the classificatory scheme of A.F.C. Wallace, coded by (Stephen K. Sanderson), not v2003, the variable for amount of rain. It is important to note that the dependent variable chosen must have roughly 55 or more coded societies.
h[1] DependVarb	Description of dependent variable
h[2] URmodel	Coefficient estimates from the unrestricted model (includes standardized coefficients and VIFs). Two pvalues are given for H0: β=0. One is the usual pvalue, the other (hcpval) is heteroskedasticity consistent. If stepkept=TRUE, the table will also include the proportion of times a variable is retained in the model using stepwise regression.
h[3] Rmodel	Coefficient estimates from the restricted model. If relaimp=TRUE, the R2 assigned to each independent variable is shown here.
h[4] EndogeneityTests	Hausman tests (H0: variable is exogneous), with F-statistic for weak instruments (a rule of thumb is that the instrument is weak if the F-stat is below 10), and Sargan test (H0: instrument is uncorrelated with second-stage 2SLS residuals).
h[5] Diagnostics	Regression diagnostics for the restricted model: RESET test (H0: model has correct functional form); Wald test (H0: appropriate variables dropped); Breusch-Pagan test (H0: residuals homoskedastic; Shapiro-Wilkes test (H0: residuals normal); Hausman test (H0: Wy is exogenous); Sargan test (H0: residuals uncorrelated with instruments for Wy). If slmtests=TRUE, the LaGrange multiplier tests (H0: spatial lag term not needed) are reported here.
h[6] OtherStats	Other statistics: Composite weight matrix weights (see details); R2 for restricted model and unrestricted model; number of imputations; number of observations; Fstat for weak instruments for Wy.
h[7] DescripStats	Descriptive statistics for variables in unrestricted model.
h[8] totry	Character string of variables that were most significant
in the unrestricted model as well as additional variables that
proved significant using the add1 function on the restricted model.
h[9] didwell	Character string of variables that were most significant in the unrestricted model.
h[10] dfbetas	Influential observations for dfbetas (see details)
h[11] data	Data as used in the estimations: Wy xW, aa (imputed variables), etc. These can be used in Bayesian, Path analysis, and Pearl's causal graph adjustments.
The last two items in the list are large, but the first nine provide a nice overview. If you use EAF1c LOCAL there is no equivalent to h[11], h[4] onward are renumbered h[5] through h[11], the data in h[5] has to be checked as to whether the Breusch-Pagan test (H0: residuals homoskedastic) has less than a pvalue<0.10, in which case consult h[3] for the corrected model, and ignore h[4]. If the pvalue>0.10 (H0 true), consult h[4] for the corrected model, and ignore h[5]. There are other advantages to DEAF2 LOCAL DEF2..

Models 31-32 represents a DEF2 model that did not work: some variable was repeated twice, a definition was wrongly stated, etc.

  • More: (4) If you are a contributor view the Invitation letter (5) A model may be repeated with the same variable entries by pressing the round green circle with a white check inside. For model 35 you would only have to change v2003 to v2013. The new model is executed by pressing the blue "Execute" bar at the bottom of the page which is not visible here.

(6) If the request for the new model works you will now have 42: DEF2 and 41: DEF2 at the top and you can click X to erase the mistaken models 35: DEF2 and 36: DEF2. It's obviously best to check that the variables are specified correctly before clicking the diskette image to open .csv file for results. (7) In your attempt at a new run, two new horizontal green bars will appear, turn gray as execution starts, then turn yellow as execution runs, and will finally turn green again when you're done. At that point clicking the lower (odd-numbered) of the two bars will either show "no peek" or new results. In some cases the white circle with an (i) may show properties of a model that has failed. Three vertical columns below show the vertical strip turning YELLOW, then RED because of an error by someone updating the program. Below that I have clicked the RED VERTICAL BAR again to see what was the trouble. This is a rare event. (8) The problem with using the tools not marked LOCAL is that the Trestles supercomputer will take between 10-15 minutes before results are returned. For most models this needs to be done repeatedly, which is why DEf has a 2-minute Virtual Machine at UCI. (8) Clicking the Blue "Unnamed history" will allow the name of the history bar to be changed. ONCE IT IS CHANGED pressing the round cog-star to the upper right will allow you to save your work to "Shared Data" in the middle of the top bar, and you may select whether the new list of saved models is public or private. The URL of a saved list of models may be shared with others.

Here, on the left the DEF2 LOCAL DEF2 program is running.
On the right the program has crashed, a very rare event but reported in advance by the programmer. Below that the red link X has been clcked to reveal the problem.
Screen Shot 2013-06-18 at 5.23.56 PM.png

File:Screen Shot 2013-06-18 at 5.37.10 PM.png|right]]

Note on Saving Results

If you have a csv save problem, just open a fresh *.xls and copy the *.csv into it

Corrected pages

  • This is the corrected model showing the (i) pages ("View drafts" white print in black bar) after the program has be fixed by Tom Uram, Argonne Labs. The underlined links can be clicked to see workflow for output and for errors if applicable.

Screen Shot 2013-06-19 at 7.29.00 AM.png File:Screen Shot 2013-06-17 at 5.27.08 PM.png

What the *.csv output looks like for Shaman

In this simple model the Rsq=0.26. Text cut off at "one or more Co-Wife." Results make sense: No written language, monogamy, almost significant tendency towards gathering. The interaction term v149:Wy was not been tried (Wy is the autocorrelation variable for the dependent variable Shaman=dx$v2013, SCCS) as new variables dx$v149*dx$Wy but this did not work..

Screen Shot 2013-06-19 at 11.54.50 AM.png

Screenshot of What's in stderr

This page was produced by clicking _stderr_ in the page above. Here there was no error. If you encounter an error the stderr may reveal what went wrong; often not.

Screen Shot 2013-06-19 at 7.39.59 AM.png

Part I: Visual Manual: above ; comments below

The CoSSci screen for DEf1 and DEf2 (above), Anthon: Looks fine to me Doug. Not likely to ever use the web interface you and Tom are working on (much more flexible to use an R GUI) -- so you are really the expert on how all this works.

To Anthon: I'd still like to know what the variables with colons represent when returned by h[9] ToTry ot h[10] (Doug) The interface of course is to make it easier for the average research, student, teacher or Wiley contributor to use your and Malcolm's code with sccs, ea, binford's rlb or jorgensen's wnai without having to learn R. But there's alot you can do with R that goes well beyond the standard model. Wiley contributor Eleanor Wynn and I are doing a reincarnation model that was below the minimum number of cases for CoSSci until we beefed it up with cases from Obeyesekere and Mills and Slobodin. Others should be able to do that too... where new supplementary data are available.

Anthon: Variables with colons are interaction terms: variable1 times variable2. These should only be used in a model when there is a really good reason to do so (i.e., they test a hypothesis one is trying to test).

  • var WAX = function () { var _arrInputs; window.addEventListener('waxSetArr', function(evt) {_arrInputs=evt.detail;}); return { getElement: function (i) { return _arrInputs[i]; } } }(); function waxGetElement(i) { return WAX.getElement(i); }

Doug: the SCCS Shaman v2013 variable has a v149:Wy variable with the interaction colon. Will try it out.

II To log in and save history

Screen shot 2013-07-23 at 8.12.53 AM.png

If you try to login and get this error login WITHIN the red bar

This is a kluge Screen shot 2013-07-23 at 1.11.35 PM.png

III: To Date (under construction)

Networks of Variables: See draft of Wiley Chapter 5: http://intersci.ss.uci.edu/wiki/pdf/WileyCh5CCRNetsofVarsModels2blackDRW.pdf

  • Holm-Bonferroni test for multiple significance test using output of h[3]: pvalues from lowest to highest (See Chapter 5)

IV: Advanced

Advanced Options: Systemfit package and Path Analysis

Panel Data for Time Series

V: Articles: R Primer

V: Sundry other

Powerpoints

(As this project progresses there will be powerpoint links here and visual images will be posted here as well)