Data Set | FileName | Record Count | Comments |
---|---|---|---|
National Waiting List | TPP_NWL_ClockStops_20231124_0819.txt | 195,596 | This is a cumulative load eg we only send the latest weeks data to be appended. |
National Waiting List | TPP_NWL_Diagnostics_20231124_0819.txt | 945,519 | This is a cumulative load eg we only send the latest weeks data to be appended. |
National Waiting List | TPP_NWL_OpenPathways_20231124_0819.txt | 6,599,819 | This is a cumulative load eg we only send the latest weeks data to be appended. |
Antiviral Data | TPP_Antiviral_20231124_0823.txt | 109,611 | This is a full refresh of all data. |
PHE Data | TPP_PHE_Tests_Positive_20231124_0827.txt | 6,132,4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#1 [internal] load build definition from Dockerfile | |
#1 transferring dockerfile: 1.09kB 0.0s done | |
#1 DONE 0.0s | |
#2 [internal] load metadata for docker.io/ebmdatalab/datalab-jupyter:python3.8.1-2328e31e7391a127fe7184dcce38d581a17b1fa5 | |
#2 DONE 0.5s | |
#3 [internal] load .dockerignore | |
#3 transferring context: 2B done | |
#3 DONE 0.0s |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This log output shows Chris running `python run.py` on Windows. It shows two issues. | |
1. A syntax error in jupyterlab | |
2. A config error (presumably due to deprecated config) for jupyterlab | |
```txt | |
(base) C:\Users\cwood\Documents\GitHub\rich_test_1>python run.py | |
Building docker image. This may take some time (particularly on the first run)... | |
#0 building with "default" instance using docker driver | |
#1 [internal] load build definition from Dockerfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
from PIL import Image | |
# This is the complex parsing. It locates every single italic character in the text, | |
# and then adds a custom inline style to it | |
js = """document.querySelectorAll('*').forEach(element => { | |
const fontStyle = window.getComputedStyle(element).fontStyle; | |
if (fontStyle === 'italic') { | |
element.style.backgroundColor = 'lightgrey'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Hacky script to download audio from a BBC interview and transcribe, with OpenAI tools | |
""" | |
import subprocess | |
from optparse import OptionParser | |
# Define command line options |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select s1.d, n1, n2, cast(n2 as decimal) / cast(n1 as decimal) | |
from | |
( | |
select d, count(*), n1 from ( | |
select convert(varchar(7), admission_date, 23) d | |
from apcs_cost c | |
join apcs a | |
on c.apcs_ident = a.apcs_ident | |
) s | |
group by d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Uploading file for patient_index_date | |
CREATE TABLE #tmp1_patient_index_date_file ( | |
patient_id BIGINT, | |
patient_index_date DATE | |
) | |
GO | |
-- Query for patient_index_date |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Query for dereg_date | |
SELECT * INTO #dereg_date FROM ( | |
SELECT | |
t.Patient_id, | |
end_date AS value | |
FROM ( | |
SELECT | |
Patient_ID AS patient_id, | |
MAX(EndDate) AS end_date | |
FROM |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sex 115 ############################################################ | |
age 114 ############################################################ | |
imd 84 ############################################ | |
ethnicity 67 ################################### | |
region 64 ################################## | |
stp 63 ################################# | |
care_home_type 51 ########################### | |
registered 47 ######################### | |
bmi 45 ######################## | |
chronic_cardiac_disease 44 ####################### |
This file has been truncated, but you can view the full file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Query for age | |
SELECT * INTO #age FROM ( | |
SELECT | |
Patient.Patient_ID AS patient_id, | |
CASE WHEN | |
dateadd(year, datediff (year, DateOfBirth, '20200331'), DateOfBirth) > '20200331' | |
THEN | |
datediff(year, DateOfBirth, '20200331') - 1 | |
ELSE | |
datediff(year, DateOfBirth, '20200331') |
NewerOlder