Rank: 40 based on 629 downloads (last 30 days) and 5 files submitted
photo

Jimmy Shen

E-mail
Company/University
Rotman Research Institute

Personal Profile:

http://research.baycrest.org/~jimmy

Professional Interests:

 

Watch this Author's files

 

Files Posted by Jimmy View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
07 Mar 2013 Screenshot Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen analyze, nifti, niftl, image, medical, isotropic 515 113
  • 4.65789
4.7 | 41 ratings
04 Dec 2012 geotiffwrite Write a 2D or 3D array to a single or multi-band GeoTIFF file Author: Jimmy Shen earth sciences, dem, earth science, gps, gis, image 52 20
  • 4.88889
4.9 | 9 ratings
22 Feb 2011 Load BIOPAC ACQ (AcqKnowledge for PC) data Load BIOPAC's *.acq file (AcqKnowledge for Windows data format). Author: Jimmy Shen medical, biopac acqknowledge, acq, eeg, file, data 21 15
  • 4.625
4.6 | 8 ratings
16 Apr 2009 Screenshot Resampling volume or image with affine matrix Use affine matrix to convert 3D vol or 2D img to orthogonal one with corresponding affine matrix. Author: Jimmy Shen affine, 2d, 3d, image, volume, mapping 33 9
  • 4.5
4.5 | 6 ratings
22 Aug 2008 Screenshot 3D Bresenham's line generation Generate X Y Z coordinates of a 3D Bresenham's line between two given points Author: Jimmy Shen specialized, plotting, 3d, bresenham algorithm, raster, line 8 1
  • 4.0
4.0 | 1 rating
Comments and Ratings by Jimmy View all
Updated File Comments Rating
05 Jul 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen

Data for "plot" only contain the coordinates information, while data for "make_nii" need intensity value which is assumed to be distributed on a grid with its coordinates from 1 to the dimention of the grid. In addition, unlike plot, coordinates for images contain only the integer. Therefore, you cannot directly extract the data from a plot and make it to an image.

Export your plot data to an image would be an easy alternative. I think you already did good. All you have to do is to hide the background image and the axes before you export the plot to an image. Here's how to do so:

1. Before export, use mouse click your plot (make it active);

2. Hide the axes by running:

set(gca,'visible','off');

3. Hide the background image by running:

h = get(gca,'child');
for i=1:length(h)
if strcmpi(get(h(i),'type'),'image')
set(h(i),'visible','off');
end
end

4. Export the plot to an image. Now it does not have the background and axes.

14 May 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen

"collapse_nii_scan" is used to integrate multiple single-volume NIfTI or ANALYZE files into one multiple-volume NIfTI file. In your case, if you want to concatenate two 4D NIfTI images into one 4D NIfTI images, you should apply "expand_nii_scan" to your both 4D images. All volumes must be in the same folder, and make sure the file name is correctly renamed (i.e. from 001~999 instead of 1~999). Then, apply "collapse_nii_scan" to all those expanded volumes in the specific folder, and you will get a concatenated 4D NIfTI image file.

14 Sep 2012 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen

Hi Zhi:

"collapse_nii_scan.m" will do the job.

Hi Samiy:

This tool can not be used to extract spinal cord. However, once you extracted it and saved into another Analyze/NIfTI file, this tool can load the data into MATLAB for further processing.

11 Jul 2012 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen

Received the image, and it is a special RGB data type one. The nii.img ranges from 0 to 1 as usual, but the output value needs to be scaled by (glmax-glmin)+glmin.

10 Jul 2012 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen

Would you please send me this image, so I can take a look into it for you tomorrow afternoon.

Comments and Ratings on Jimmy's Files View all
Updated File Comment by Comments Rating
05 Jul 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen NH

Perfect! Thank you!

05 Jul 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen Shen, Jimmy

Data for "plot" only contain the coordinates information, while data for "make_nii" need intensity value which is assumed to be distributed on a grid with its coordinates from 1 to the dimention of the grid. In addition, unlike plot, coordinates for images contain only the integer. Therefore, you cannot directly extract the data from a plot and make it to an image.

Export your plot data to an image would be an easy alternative. I think you already did good. All you have to do is to hide the background image and the axes before you export the plot to an image. Here's how to do so:

1. Before export, use mouse click your plot (make it active);

2. Hide the axes by running:

set(gca,'visible','off');

3. Hide the background image by running:

h = get(gca,'child');
for i=1:length(h)
if strcmpi(get(h(i),'type'),'image')
set(h(i),'visible','off');
end
end

4. Export the plot to an image. Now it does not have the background and axes.

05 Jul 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen NH

Thank you very much for this useful product. I do have a question, if anyone could help me out...

I loaded a .nii file, did some processing and have a new plot that I would like to extract data from and ultimately save as .nii. It is a simple plot that was a result of finding the boundaries of an object. I extracted the data from the plot and entered it into a cell, but the "make_nii" function does not support this datatype. I tried converting the cell to a .mat, but that did not produce a satisfactory result either. I also tried saving the plot as an image and then using "make_nii," which worked, but the result included the border and axes of the image. I want only the data, without the background or axes. Does anyone have any suggestions?

25 Jun 2013 Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen Orestis

10 Jun 2013 Resampling volume or image with affine matrix Use affine matrix to convert 3D vol or 2D img to orthogonal one with corresponding affine matrix. Author: Jimmy Shen Hurley, Samuel

This is great. I replaced a hacked solution of my own that worked terribly with this in literally less that 5 minutes.

Top Tags Applied by Jimmy
image, 3d, format, medical, save
Files Tagged by Jimmy View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
07 Mar 2013 Screenshot Tools for NIfTI and ANALYZE image Load, save, make, reslice, view (and edit) both NIfTI and ANALYZE data on any platform Author: Jimmy Shen analyze, nifti, niftl, image, medical, isotropic 515 113
  • 4.65789
4.7 | 41 ratings
04 Dec 2012 geotiffwrite Write a 2D or 3D array to a single or multi-band GeoTIFF file Author: Jimmy Shen earth sciences, dem, earth science, gps, gis, image 52 20
  • 4.88889
4.9 | 9 ratings
22 Feb 2011 Load BIOPAC ACQ (AcqKnowledge for PC) data Load BIOPAC's *.acq file (AcqKnowledge for Windows data format). Author: Jimmy Shen medical, biopac acqknowledge, acq, eeg, file, data 21 15
  • 4.625
4.6 | 8 ratings
16 Apr 2009 Screenshot Resampling volume or image with affine matrix Use affine matrix to convert 3D vol or 2D img to orthogonal one with corresponding affine matrix. Author: Jimmy Shen affine, 2d, 3d, image, volume, mapping 33 9
  • 4.5
4.5 | 6 ratings
22 Aug 2008 Screenshot 3D Bresenham's line generation Generate X Y Z coordinates of a 3D Bresenham's line between two given points Author: Jimmy Shen specialized, plotting, 3d, bresenham algorithm, raster, line 8 1
  • 4.0
4.0 | 1 rating

Contact us