Metadata extraction module of DICOM images.
-
Radiology-CDM extracts Metadata and Pixeldata from DICOM file, which is the original radiology image, and combines the data required for RCDM and stores it in DB format and converts it into CDM.
-
Just copy and paste this code into your Rstudio!
All you have to do is just change 'path' and 'core' in DICOMHeaderList function.
RadiologyCDM function will read all of the DICOM files under the 'path' you've specified.
Now check the variable 'Radiology_Image_Table' and, 'Radiology_Occurrence_Table'! -
If you want to observe result of database analysis, you can use RCDMShinyViewer function.
All you have to do is to download 'LoincRsnaRadiologyPlaybook.csv' file which is uploaded on this github page.
This file is a mapping table for radiolgy terminologies.
devtools::install_github('ABMI/Radiology-CDM/RadETL')
library(RadiologyCDM)
library(dplyr)
library(ParallelLogger)
library(digest)
library(shiny)
library(ggplot2)
library(DT)
#Please don't change the name of variables : 'DICOMList', 'Radiology_Occurrence_Table', 'Radiology_Image_Table', 'LoincRsnaRadiologyPlaybook'
DICOMList<-DICOMHeaderList('path to DICOM files', core = 4)
Radiology_Occurrence_Table<-radiologyOccurrenceTable(DICOMList)
Radiology_Image_Table<-radiologyImageTable(DICOMList)
LoincRsnaRadiologyPlaybook<-read.csv('LoincRsnaRadiologyPlaybook.csv')
RCDMShinyViewer(Radiology_Occurrence_Table, Radiology_Image_Table)