I have web log analysis data (AWStats) from a university library website. I'm looking at the number of visits per month divided by the number of faculty plus student enrollment (visits per headcount). This shows a downward trend, along with strong seasonality. Also, the undergrad enrollment has gone up steadily the last few years, while the graduate enrollment has stayed flat.

Therefore, I am fitting a regression with ARMA errors model, with the ratio of grad student headcount to undergrad headcount as an explanatory variable (since graduate students use the library more than undergrads). My interest is in explaining the downward trend, not forecasting. The time series plots for the response and explanatory variables look very similar, seasonal with spikes in the summer and a downward trend.

I have taken regular and seasonal differences for both variables and fit a model with ARMA errors. The estimate for the ratio is significant.

My question is, how can I estimate how much of the downward trend the does the regression variable explain? I don't think it explains all of it.

The AIC without the regression term is -20.02, and with the regression term is -35.16. The estimate of the slope is 3.71.

I'm more familiar with SAS, and I am using proc arima, but I could use R as well.

I want to emphasize that the question is not prediction. As there are more options to gather information online, it is natural that there might be less library usage per person. The question, at our particular institution, can part of the per-person usage be explained by the fact that the proportion of grad students in the entire student enrollment is less, as undergrad enrollment rises? We know, from survey data, that grad students use the library more. Then how much of the trend is attributable to that? 10%? 20%? 50%?

I will try posting some graphs, output, etc. when I get a chance.

  • 1
    $\begingroup$ If you have access to SAS, also try using Proc UCM, it is very flexible in handing explanatory variables. In addition it could also handle level shifts/outliers in your data. $\endgroup$
    – forecaster
    Nov 14 '13 at 14:40
  • $\begingroup$ I haven't read up on Proc UCM, I wasn't sure what it was doing. It's not using arima, right? I did want to know whether there was in fact a trend downward. I used regression with month dummy variables. $\endgroup$
    – user34773
    Nov 14 '13 at 17:24
  • 1
    $\begingroup$ I would recommend Proc UCM over ARIMA because, it is much more flexible and more interpretable especially when you want your time series data to be decomposed into trend and seasonal component. you can go to SAS website for more help. I can provide you with an eexample below. If you can post your data, I can see if I can model the data in proc ucm. support.sas.com/documentation/cdl/en/etsug/60372/HTML/default/… $\endgroup$
    – forecaster
    Nov 14 '13 at 20:01

Your approach is generally correct but the devil is in the details. Unwarranted differencing can lead to very spurious results. Ignoring anomalies (pulses/seasonal pulses,level shifts and local time trends can be the downfall of a tf model. Changes in parameters over time or changes in error variance over time need to be investigated. I am afraid that both SAS and R are not up to these challenges. You might post your data or send it to me at my email address and I will try and answer your specific questions and post an analysis to the web. If your data is confidential then we can do this off line although I would prefer to enlighten others as to what can be done.

In closing ... it is generally speaking not a good idea to use percentages but rather use both observed series when constructing a model. Care should be taken to distinguish between trend and level shift activity as most software including JMP can not detect time trend changes which is precisely what you are looking for. Some software (JMP in particular) assume that both the parameters and the error variance are constant over time. Be wary of such simplistic solutions as they are often wrong and need remedial treatment. it is interesting to me that SAS's defaults for JMP is to NOT detect level shifts. I wonder why ?

  • $\begingroup$ In your last paragraph, do you mean instead of using the ratio, use each variable separately (undergrad enrollment and grad enrollment)? $\endgroup$
    – user34773
    Nov 14 '13 at 17:22
  • $\begingroup$ Yes predict visits using historical data for both students and faculty. Use both inpout series to predict visits. $\endgroup$
    – IrishStat
    Nov 14 '13 at 18:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.