Closed camcaan closed 5 years ago
Hi @camcaan can you please clarify what are you trying to do here?
Please also close the issue and post the solution (if any) so it doesn't get mixed up with currently active issues
I was something simple i didn't know how to do. basically i had a read code file and clinical and a medical dictionary file and i wanted to look how many patients had those read code in their diagnoses in the clinical file. so I did (1) joined the clinical file and medical file by medcode column (2) scaned for the read code in the joined file
dx <- clinical %>% left_join(medical)
PC_diagnoses <- dx %>% filter(readcode %in% read_code$readcode) %>% mutate(AD= 1)
data frame with read codes
readcodes <- ("<>")
clinicaldata joining medical.txt dictionary
DX <- clinical_data %>% left_join(medical.txt)
checking the diagnoses based on read codes
PC_DX <- DX %>% filter(readcodes == "F110.00") %>% distinct(epatid) %>% mutate(AD=1)