Print

Print


Hi,

Sending to the list so everyone knows - yes, I was using the deSolve
package.

If you just install the package, the code should work. As I said before,
it's a very crude model and I'm probably going to focus on it too much
more but I'm definitely interested in others' thoughts!

In response to John: the idea here was to demonstrate what "flattening
the curve" was about. I agree it would be good to model it against known
data - but I think that will just show how crude it is!

NB, there's also an interesting site called https://www.flattenthecurve.com/


Best wishes,

     -- Andrei

On Mon, Mar 16, 2020 at 09:24:06PM +0000, John Whittington wrote:
>    Hi both,
> 
>    Just a thought.  If you were interested in developing models which show
>    what can/could be achieved (with appropriate management etc.) (maybe in
>    addition to models showing what might happen without 'appropriate
>    management'!) I might suggest that a test of your models would perhaps be
>    to see whether they can get anywhere near predicting what subsequently
>    happened in China and Korea on the basis only of data relating to the
>    early stages of their outbreaks.
> 
>    Kindest Regards,
>    John
> 
>    At 18:34 16/03/2020, Greg Dropkin wrote:
> 
>      hi Andrei
> 
>      my first thought was too naive. I now think this is a "delay
>      differential
>      equation", which means the R package deSolve might work, which maybe you
>      are already using (you haven't said what package but your code just
>      after
>      "##Solve equations" uses "ode" - which is in deSolve, though probably
>      also
>      in other packages).
> 
>      anyway if I can learn deSolve I'll look at your model.
> 
>      Greg
> 
>      > Hi Greg and all,
>      >
>      > yes, it is an ordered differential equation. I'm no mathemetician so
>      not
>      > very good with matrices - on my reading list for today! Although I'm
>      > also on call so we'll see how much time I have... Re exponentials:
>      > yes. I think we're still very early on in the curve unfortunately :/
>      >
>      > Best wishes,
>      >
>      >      -- Andrei
>      >
>      > On Sun, Mar 15, 2020 at 07:40:54AM -0000, Greg Dropkin wrote:
>      >> hi Andrei, all
>      >>
>      >> I'll get to this later but first thought is that your model looks
>      like a
>      >> linear differential equation.
>      >>
>      >> put v = state vector whose components are the compartments.
>      >>
>      >> dv/dt = A%*%v where A is a matrix with a lot of 0s and some
>      parameters
>      >> which you've estimated from the literature. If that's right, the
>      >> solution
>      >> is
>      >>
>      >> v(t) = exp(tA)%*%v(0)
>      >>
>      >> to compute exp(tA), diagonalise it.
>      >>
>      >> anyway I'll look when I can.
>      >>
>      >> Greg
>      >>
>      >> > Hi Greg and all,
>      >> >
>      >> > Yes, I agree with you - I think (am hoping?!) this is going to
>      >> backfire
>      >> > quite spectacularly on the conservatives. A silver lining we might
>      not
>      >> > want...
>      >> >
>      >> > I've now put my code up on the web:
>      >> >
>      >> >  * [1]https://0xacab.org/asm/covid19
>      >> >
>      >> > I will reiterate it is *very* crude - the number of deaths is circa
>      10
>      >> > million or more for the UK, which is clearly ridiculous. The main
>      >> point
>      >> > I was trying to make was about "flattening the curve" - I want to
>      show
>      >> > how this relates to ITU bed occupation at some point, but don't
>      have
>      >> > time at present. I'm also not retired and guess I should do some
>      >> 'real'
>      >> > work at some point ;-)
>      >> >
>      >> > Anyway, would love to hear your thoughts about it. I don't have any
>      >> data
>      >> > to hand about long term immunity - my guess is it's pretty high,
>      but
>      >> it
>      >> > really depends on the disease. For instance, we all have *some*
>      >> immunity
>      >> > to the flu, but different strains mutate and circulate etc, so that
>      >> > level is different every year.
>      >> >
>      >> > Tomorrow I'm on call, I'm not quite sure if/when I'll be able to
>      catch
>      >> > up with the flood of emails that is bound to come to this list. But
>      >> > great to see the list being used in productive ways!
>      >> >
>      >> > Best wishes,
>      >> >
>      >> >      -- Andrei
>      >> >
>      >> > On Sat, Mar 14, 2020 at 10:15:31PM -0000, Greg Dropkin wrote:
>      >> >> Date: Sat, 14 Mar 2020 22:15:31 -0000 (UTC)
>      >> >> hi
>      >> >>
>      >> >> even without any modelling, if they think 60% is the threshold
>      they
>      >> are
>      >> >> aiming for over 30m adults to be infected, which means over
>      300,000
>      >> >> deaths
>      >> >> at 1%, and 100,000 deaths at 0.3%. Which you would have thought is
>      >> >> political suicide, once the public realises.
>      >> >>
>      >> >> if time permits I'll try your model and send you some R code to
>      >> compare
>      >> >>
>      >> >> Do you have data for other diseases on the percentage of survivors
>      >> who
>      >> >> get
>      >> >> long term immunity?
>      >> >>
>      >> >> Greg
>      >> >>
>      >> >> > Hi,
>      >> >> >
>      >> >> > Paul Fine is amazing, he taught me loads about infectious
>      disease
>      >> >> > epidemiology and was the one who got me interested in the
>      subject
>      >> >> > (albeit, as a secondary interest/hobby - my main focus is
>      perinatal
>      >> >> and
>      >> >> > non-communicable disease epidemiology). Interestingly enough, he
>      >> >> started
>      >> >> > life as a veterinarian before getting into human epi...
>      >> >> >
>      >> >> > Anyway, the UK's herd immunity idea is, put mildly, bollocks.
>      I've
>      >> >> > written another post today in which I've started to explain some
>      of
>      >> >> the
>      >> >> > flaws with the UK strategy although I haven't completely
>      elaborated
>      >> >> them
>      >> >> > - don't want to freak people out too much all at once!  Please
>      feel
>      >> >> free
>      >> >> > to comment, either directly on the article or on list or just
>      >> directly
>      >> >> > to me via email. Both articles I've written are on my site:
>      >> >> >
>      >> >> >  * [2]https://www.andreimorgan.net
>      >> >> >
>      >> >> > Best wishes,
>      >> >> >
>      >> >> >      -- Andrei
>      >> >> >
>      >> >> > On Sat, Mar 14, 2020 at 09:25:02PM +0000, Thomas Cox wrote:
>      >> >> >> I think the first two paragraphs should have made that clear.
>      >> >> >>
>      >> >> >> Abstract
>      >> >> >>
>      >> >> >> The term “herd immunity” is widely used but carries a variety
>      of
>      >> >> >> meanings [17]. Some authors use it to describe the proportion
>      >> immune
>      >> >> >> among individuals in a population. Others use it with reference
>      to
>      >> a
>      >> >> >> particular threshold proportion of immune individuals that
>      should
>      >> >> lead
>      >> >> >> to a decline in incidence of infection. Still others use it to
>      >> refer
>      >> >> to
>      >> >> >> a pattern of immunity that should protect a population from
>      >> invasion
>      >> >> of
>      >> >> >> a new infection. A common implication of the term is that the
>      risk
>      >> of
>      >> >> >> infection among susceptible individuals in a population is
>      reduced
>      >> by
>      >> >> >> the presence and proximity of immune individuals (this is
>      >> sometimes
>      >> >> >> referred to as “indirect protection” or a “herd effect”). We
>      >> provide
>      >> >> >> brief historical, epidemiologic, theoretical, and pragmatic
>      public
>      >> >> >> health perspectives on this concept.
>      >> >> >>
>      >> >> >> Though coined almost a century ago [8], the term “herd
>      immunity”
>      >> was
>      >> >> not
>      >> >> >> widely used until recent decades, its use stimulated by the
>      >> >> increasing
>      >> >> >> use of vaccines, discussions of disease eradication, and
>      analyses
>      >> of
>      >> >> the
>      >> >> >> costs and benefits of vaccination programs. An important
>      milestone
>      >> >> was
>      >> >> >> the recognition by Smith in 1970 [9] and Dietz in 1975 [10] of
>      a
>      >> >> simple
>      >> >> >> threshold theorem—that if immunity (ie, successful vaccination)
>      >> were
>      >> >> >> delivered at random and if members of a population mixed at
>      >> random,
>      >> >> such
>      >> >> >> that on average each individual contacted R0 individuals in a
>      >> manner
>      >> >> >> sufficient to transmit the infection [11, 12], then incidence
>      of
>      >> the
>      >> >> >> infection would decline if the proportion immune exceeded (R0
>      −
>      >> >> 1)/R0,
>      >> >> >> or 1 1/R0. This is illustrated in Figures 1 and 2.
>      >> >> >>
>      >> >> >>
>      >> >> >> Thomas Cox PhD RN
>      >> >> >> [log in to unmask]
>      >> >> >>
>      >> >> >>
>      >> >> >>      On Saturday, March 14, 2020, 05:13:28 PM EDT, John
>      >> Whittington
>      >> >> >> <[log in to unmask]> wrote:
>      >> >> >>
>      >> >> >>  At 20:59 14/03/2020, Thomas Cox wrote:
>      >> >> >> >and yet...
>      >> >> >> > [3]https://academic.oup.com/cid/article/52/7/911/299077
>      >> >> >>
>      >> >> >> After a very quick skip through, that all seems to be about
>      >> >> >> immunological herd immunity in the sense I described it.  Could
>      >> you
>      >> >> >> perhaps direct me to the part which you were wanting to bring
>      to
>      >> my
>      >> >> >> attention?  Thanks
>      >> >> >>
>      >> >> >> Kind Regards,
>      >> >> >>
>      >> >> >>
>      >> >> >> John
>      >> >> >>
>      >> >> >>
>      ----------------------------------------------------------------
>      >> >> >> Dr John Whittington,      Voice:    +44 (0) 1296 730225
>      >> >> >> Mediscience Services      Fax:      +44 (0) 1296 738893
>      >> >> >> Twyford Manor, Twyford,    E-mail:  [log in to unmask]
>      >> >> >> Buckingham  MK18 4EL, UK
>      >> >> >>
>      ----------------------------------------------------------------
>      >> >> >>
>      >> >> >>
>      >> >> >>
>      >> >> >> ******************************************************
>      >> >> >> Please note that if you press the 'Reply' button your
>      >> >> >> message will go only to the sender of this message.
>      >> >> >> If you want to reply to the whole list, use your mailer's
>      >> >> >> 'Reply-to-All' button to send your message automatically
>      >> >> >> to [log in to unmask]
>      >> >> >> Disclaimer: The messages sent to this list are the views of the
>      >> >> sender
>      >> >> >> and cannot be assumed to be representative of the range of
>      views
>      >> held
>      >> >> by
>      >> >> >> subscribers to the Radical Statistics Group. To find out more
>      >> about
>      >> >> >> Radical Statistics and its aims and activities and read current
>      >> and
>      >> >> past
>      >> >> >> issues of our newsletter you are invited to visit our web site
>      >> >> >> [4]www.radstats.org.uk.
>      >> >> >> *******************************************************
>      >> >> >
>      >> >> > --
>      >> >> > Andrei Morgan MRCPCH, MSc, PhD (Epidemiology / Neonatology)
>      >> >> > [5]https://www.andreimorgan.net
>      >> >> >
>      >> >> > Honorary Clinical Lecturer,
>      >> >> > Department of Neonatology,
>      >> >> > Institute for Women's Health,
>      >> >> > University College London
>      >> >> >
>      >> >> >
>      >> >> > ******************************************************
>      >> >> > Please note that if you press the 'Reply' button your
>      >> >> > message will go only to the sender of this message.
>      >> >> > If you want to reply to the whole list, use your mailer's
>      >> >> > 'Reply-to-All' button to send your message automatically
>      >> >> > to [log in to unmask]
>      >> >> > Disclaimer: The messages sent to this list are the views of the
>      >> sender
>      >> >> and
>      >> >> > cannot be assumed to be representative of the range of views
>      held
>      >> by
>      >> >> > subscribers to the Radical Statistics Group. To find out more
>      about
>      >> >> > Radical Statistics and its aims and activities and read current
>      and
>      >> >> past
>      >> >> > issues of our newsletter you are invited to visit our web site
>      >> >> > [6]www.radstats.org.uk.
>      >> >> > *******************************************************
>      >> >> >
>      >> >>
>      >> >>
>      >> >
>      >> > --
>      >> > Andrei Morgan MRCPCH, MSc, PhD (Epidemiology / Neonatology)
>      >> > [7]https://www.andreimorgan.net
>      >> >
>      >> > Honorary Clinical Lecturer,
>      >> > Department of Neonatology,
>      >> > Institute for Women's Health,
>      >> > University College London
>      >> >
>      >> >
>      >>
>      >>
>      >
>      > --
>      > Andrei Morgan MRCPCH, MSc, PhD (Epidemiology / Neonatology)
>      > [8]https://www.andreimorgan.net
>      >
>      > Honorary Clinical Lecturer,
>      > Department of Neonatology,
>      > Institute for Women's Health,
>      > University College London
>      >
>      >
> 
>      ******************************************************
>      Please note that if you press the 'Reply' button your
>      message will go only to the sender of this message.
>      If you want to reply to the whole list, use your mailer's
>      'Reply-to-All' button to send your message automatically
>      to [log in to unmask]
>      Disclaimer: The messages sent to this list are the views of the sender
>      and cannot be assumed to be representative of the range of views held by
>      subscribers to the Radical Statistics Group. To find out more about
>      Radical Statistics and its aims and activities and read current and past
>      issues of our newsletter you are invited to visit our web site
>      [9]www.radstats.org.uk.
>      *******************************************************
> 
>    John
>    ----------------------------------------------------------------
>    Dr John Whittington,       Voice:    +44 (0) 1296 730225
>    Mediscience Services       Fax:      +44 (0) 1296 738893
>    Twyford Manor, Twyford,    E-mail:   [log in to unmask]
>    Buckingham  MK18 4EL, UK            
>    ----------------------------------------------------------------
> 
> References
> 
>    Visible links
>    1. https://0xacab.org/asm/covid19
>    2. https://www.andreimorgan.net/
>    3. https://academic.oup.com/cid/article/52/7/911/299077
>    4. http://www.radstats.org.uk/
>    5. https://www.andreimorgan.net/
>    6. http://www.radstats.org.uk/
>    7. https://www.andreimorgan.net/
>    8. https://www.andreimorgan.net/
>    9. http://www.radstats.org.uk/

-- 
Andrei Morgan MRCPCH, MSc, PhD (Epidemiology / Neonatology)
https://www.andreimorgan.net

Honorary Clinical Lecturer,
Department of Neonatology,
Institute for Women's Health,
University College London


******************************************************
Please note that if you press the 'Reply' button your
message will go only to the sender of this message.
If you want to reply to the whole list, use your mailer's
'Reply-to-All' button to send your message automatically
to [log in to unmask]
Disclaimer: The messages sent to this list are the views of the sender and cannot be assumed to be representative of the range of views held by subscribers to the Radical Statistics Group. To find out more about Radical Statistics and its aims and activities and read current and past issues of our newsletter you are invited to visit our web site www.radstats.org.uk.
*******************************************************