Skip to content

Instantly share code, notes, and snippets.


Outcome MI FIT


Gain > 5% 8 0

Gain 1-5% 21 2

< 1% change 16 4

Lose 1-5% 32 18

in events_list.html replace this line:
{% assign events = site.events | sort: 'document.starts' %}
with:
{% if list_event_type %}
{% assign events = site.events | sort: 'document.starts' | where:'eventtype', list_event_type %}
{% else %}
library(lme4)
library(rethinking)
library(foreign)
library(merTools)
library(dplyr)
set.seed(1234)
setwd("~/Desktop/")
BIGN <- 10000
df <- data_frame(x=rep(0:1, BIGN/2), id=(1:BIGN)%%50) %>%
library(lme4)
library(rethinking)
library(foreign)
library(merTools)
library(dplyr)
set.seed(1234)
setwd("~/Desktop/")
BIGN <- 10000
df <- data_frame(x=rep(0:1, BIGN/2), id=(1:BIGN)%%50) %>%
c(94, 30, 149, 222, 16, 82, 18, 56, 113, 115, 96, 48, 101, 133, 109, 80, 37, 227, 117, 74, 122, 112, 214, 42, 39, 11, 68, 147, 77, 44, 61, 85, 95, 142, 20, 75, 92, 176, 57, 63, 132, 195, 229, 177, 91, 45, 138, 186, 87, 162, 171, 129, 7, 116, 158, 169, 111, 166, 6, 130, 141, 78, 27, 17, 35, 93, 210, 198, 100, 38, 153, 14, 143, 105, 83, 193, 157, 139, 32, 172)
c(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3)
c(94, 30, 149, 222, 16, 82, 18, 55, 113, 115, 96, 48, 101, 133, 109, 80, 37, 227, 117, 74, 122, 112, 214, 42, 39, 11, 67, 147, 77, 44, 61, 85, 95, 142, 20, 75, 92, 176, 57, 63, 131, 194, 230, 177, 91, 45, 138, 186, 87, 162, 171, 129, 7, 116, 158, 169, 111, 166, 6, 130, 141, 78, 27, 17, 35, 93, 210, 198, 100, 38, 153, 14, 143, 105, 83, 195, 157, 139, 32, 172)
---------------------------------------------------------
Email.address Grade
------------------------------------------------- -------
holly.jessup@students.plymouth.ac.uk A
briony.bond@students.plymouth.ac.uk A
lewis.jeffery@students.plymouth.ac.uk A
thomas.burgess@students.plymouth.ac.uk A
-----------------------------
month patient hasnohamd
------- --------- -----------
7 10015 1
7 10103 1
7 10295 1
7 10380 1