## Lecture: Stratified Regression
## Assigned Reading- Stratified Regression (use instructor's last name for password)
- Read Chapter 18 in Statistical Analysis of Electronic Health Records by Farrokh Alemi, 2020
- Slides►
- Cursor and do-while SQL commands
## AssignmentSubmit one file for all questions. Include all charts, code, and output in the same file. Start each question in a separate page or sheet. Include in the first page a summary page. In the summary page write statements comparing your work to answers given or videos. For example, "I got the same answers as the Teach One video for question 1."
- Identify parents in the Markov blanket of lung cancer.
- Verify that all comorbidties make prognosis of lung cancer worse.
- Use SQL code and parents in Markov blanket of lung cancer, to estimate survival from lung cancer.
- Use SQL to construct case/control comparisons for each comorbidity of lung cancer.
- Use SQL to estimate the intercept for parameters of the multiplicative function form. Estimate the overall k parameter for the multiplicative model.
- Report the mortality rate for patients who just have lung cancer and no other comorbidities.
- Provide the equation that calculates the risk for combination of lung cancer and its comorbidities.
- Clean the data using the following steps: The age at death is given as a row of data. For each assessment calcualte if the patient dies in 6 months from the assessment. If the patient never dies assume not dead in 6 months. At death assume that the patient has all disabilities, as is the data indicates no disabilities at death. Drop last assessment as no outcomes can be calculated from last assessment. Assume age of assessment is age at first assessment (given as the second variable) plus days to assessment/365. Residents with negative age should be dropped because of date of birth errors. Residents 100 or more years should be dropped because of small sample. Note that the analysis is done at assessment level and not at patient level. Data► Clean►
- Predict from the patient's assessments (i.e. their age, gender, and disabilities at time of assessment) if the patient is likely to die in the next 6 months and may be a candidate for hospice care. Do not use regression in these analysis and estimate the parameters using SQL. SQL► Answer►
- Calculate the k constant for the multiplicative model using SQL.
SQL►
Generate possible k values and see which one of the k values satisfy the equation:
- Use the model you have developed to predict the probability of
mortality for a 75 year old resident with urine, bowel, and toilet disabilities. Enter the case description into a table
called RecentCases, using
Create Table and Insert Value commands. Then use this table to
predict the probability of mortality for this resident.
SQL►
Make sure that the probability of mortality is adjusted to range between minimum amd maximum probabilities for different strata. Stratfied regression provides a transformed probability that should be adjusted to estimate the actual probability using this formula:
Where Max is the maximum and Min is the minimum probabilities for each strata.
- Check that all variables are positively and monotonely related to prevalence of diabetes in the county. Monotone?►
- Assign a binary variable to each variable in such a manner that when the variable is 1, diabetes is more likely.
- Create a multiplicative model for predicting diabetes.
The data are reported for a total of 22,254 visits. Visits may be 2 week or more apart. Not every patient shows for every scheduled visit. Organize the data so there is one row for each patient and each antidepressant trial (known in the data as Concat). Note that this field considers combination of antidepressants as a new antidepressant. Ignore the dose of the medication. Patients received multiple antidepressants during these trials until something worked for them. Include each time a new antidepressant was tried as a separate trial. If the patient has taken the antidepressant at any time during the trial, then mark it as 1, otherwise 0. Notice that some patients have taken the medication and others have not. Patients who have not taken a particular medication have taken other medications, so at any time we are comparing one medication to alternative treatments. The medication is considered to have caused the remission if the patient is referred to follow up portion of the study, at any point while taking the medication; i.e. the variable "Treatment_plan_equal_3" is set to 1 while taking the medication . - Clean and organize the data for analysis of bupropion
- Identify the parents in the Markov blanket of bupropion
- Create a multiplicative model of the impact of variables in the parent of Markov Blanket of bupropion and buproprion itself on remission.
- Predict remission rate for bupropion using two nearest strata SQL►
## MoreFor additional information (not part of the required reading), please see the following links: - Multi-attribute preference functions. Health Utilities Index. PubMed►
- Utility functions for health profiles PubMed►
- How decisions reveal our preferences PubMed►
This page is part of the course on Comparative Effectiveness by Farrokh Alemi PhD Home► Email► |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||