代写Bayesian statistics assignment 2023/24代做Java语言

- 首页 >> C/C++编程

Bayesian statistics assignment 2023/24

Version 1  |  Updated: 28 November 2023

1 Assignment

Prepare a short report (no more than 1,500 words) detailing your analysis and results of the ‘hospital at home’ program below. Your report should have the following sections: Introduction, Methods, Results, and Conclusions. There are several points that each section must address, which are listed in Section 3. You can include up to two plots and two tables. You should not include Stata code or unformatted, raw Stata output in your report. Please also ensure that any plots appear correctly in the submission. You will require the dataset hospital_at_home.dta.

2 Description

You work for a healthcare provider. The provider is experiencing capacity is- sues, with high bed occupancy rates, and growing waiting lists for treatment. As a result, the provider wants to know whether a ‘hospital at home’ program that provides ‘early supported discharge’ will increase throughput at the hospi- tal. In the program, patients are discharged earlier than they would otherwise have been, but with active monitoring and home-based support as required. The current mean (sd) length of hospital stay among patients in the hospital is 27.1 (24.2) days.  However, there is no additional budget for a wide scale roll out of the program, and it will only be implemented if it is likely to be cost sav- ing. A before-and-after study was conducted by the provider.  You have been tasked with analysing these data, incorporating any reasonable prior evidence, to estimate the probability that the program will be cost-saving.

The per-patient net costs of the program are (cost per bed day)*(mean difference in length of stay) - (per patient program cost). The cost per bed day is £350 and the per patient program cost is determined to be £2000.

2.1 Statistical Model

You will use a linear model to estimate the mean difference in length of stay (variable length_of_stay in the dataset). You are to estimate a model adjusted for age and sex. The statistical model, including prior distributions, for patient i is:

length_of_stay i  = β0 + β1age_zi + β2male i + δintervention i + ε i β0 ~ N(m0, s0(2))

β1 ~ N(m1, s1(2))

β2 ~ N(m2, s2(2))

δ ~ N(md, sd(2))

ε ~ N(0, σ2 )

Where the variables are labelled as they appear in the dataset. Age (age_z) has been mean standardised (to have mean zero and standard deviation one). In this model, the parameter δ is the adjusted mean difference in length of stay between those in the program and those with standard care.

2.2 Data

The data required to conduct the analysis is provided as the Stata file hospi-tal_at_home.dta. The dataset contains 567 individuals with the variables sex, age_z, and intervention corresponding to the variables in the model. Un- standardized age is provided as age.

2.3 Objectives

The two main objectives of the analysis are:

1. To estimate the adjusted mean difference in length of stay between those in the program and those with standard care, incorporating any relevant prior knowledge.

2. To estimate the probability that the program will be cost saving.

2.4 Estimating the model with MCMC

You can use any MCMC software to estimate the model described above. Here we provide some hints on using Stata’s MCMC functionality. We recommend using the bayes prefix with the regress command, which estimates the linear model. The manual for the bayes command with examples can be found on pages 54 to 124 at https://www.stata.com/manuals/bayes.pdf#bayes. The basic call for the model is:

bayes ,  prior ({ length_ of_ stay : _ cons },  normal (m0 , s0))  prior ({

length_ of_ stay : intervention },  normal (m1 , s1)),   . . .   :  regress

length_ of_ stay  age   sex   intervention

where you will need to replace m0, m1, s0, s1, etc with appropriate values, and you will need to add additional options as required. You are not required to specify a prior for σ2 and can use the default value provided by Stata.

3 Instructions

Your short report must do the following: In the methods:

1. Choose and justify prior distributions for β0, β1, β2, and δ with references to any evidence you have used to inform the prior distributions. You may wish to include a table with headings: parameter, prior mean, prior standard deviation, and/or justification to summarise your choices, or you may summarise the choices in text.

2. You will need to use MCMC to estimate the model (see Section 2.4). Choose and explain the options for the MCMC software you will use to derive any estimates, including the number of chains, iterations, and anything else you think is important.

The results section must include:

3. MCMC diagnostics for the model and an explanation for whether your believe the chains have converged.

4. A summary of the estimated model parameters, with an interpretation of the estimated mean difference in length of stay parameter δ .

5. An estimate of the probability that the program is cost saving.

The discussion section must include:

6. A summary of the findings of the analysis, including a recommendation whether to adopt the program or not.






站长地图