Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

matlab.io.fits.deleteRecord

Delete key by record number

Syntax

deleteRecord(fptr,keynum)

Description

deleteRecord(fptr,keynum) deletes a keyword by record number.

This function corresponds to the fits_delete_record (ffdrec) function in the CFITSIO library C API.

Examples

Delete the 18th keyword ("ORIGIN") in a primary array.

import matlab.io.*
srcFile = fullfile(matlabroot,'toolbox','matlab','demos','tst0012.fits');
copyfile(srcFile,'myfile.fits');
fileattrib('myfile.fits','+w');
fptr = fits.openFile('myfile.fits','readwrite');
card = fits.readRecord(fptr,18);
fits.deleteRecord(fptr,18);
fits.closeFile(fptr);

See Also

|

Was this topic helpful?