[This article was first published on Rigorous Analytics, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
The R package oro.dicom contains data input/output functions for medical imaging data that conform to the Digital Imaging and Communications in Medicine (DICOM) standard, part of the Rigorous Analytics bundle.Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
The latest version of oro.dicom (0.4.0) contains a substantial update:
- The function subroutines of readDICOMFile() have been re-written from scratch.
- The entire DICOM file is read into R using readBin(what = “raw”) and parsed in a recursive fashion. That is, the DICOM header information is processed in the (group, element) doublets until a sequence header is found. Once a sequence header is found, then the subroutine is called again… and so on and so forth… until the entire DICOM header is parsed. This has reduced the total number of lines of code and, I believe, made the process more easily digestible.
- Assuming a PixelData or SpectroscopyData field is present, the subsequent bytes will be read into a separate R data structure.
The revised code has been tested against a collection of DICOM files and works well. However, only time will tell if the modifications work against the wide variety of DICOM headers one can find. If you have DICOM data that you would like to contribute to the test suite for oro.dicom, please contact me at rigorousanalytics@gmail.com or post messages on this blog.
To leave a comment for the author, please follow the link and comment on their blog: Rigorous Analytics.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.