seasonder_exportMUSICTable {SeaSondeR} | R Documentation |
Export MUSIC Table from SeaSondeRCS Object
Description
This function generates a table containing detailed MUSIC detection data from a SeaSondeRCS
object. The output table includes geographic coordinates, signal parameters, and other metadata for each MUSIC detection.
Usage
seasonder_exportMUSICTable(seasonder_cs_object)
Arguments
seasonder_cs_object |
A |
Details
This function performs the following operations:
Retrieves the timestamp (
nDateTime
) from the header of theSeaSondeRCS
object. Defaults toas.POSIXct(0)
if unavailable.Initializes an empty data frame with predefined columns.
Retrieves MUSIC detection data, processes the Direction of Arrival (DOA) and geographic coordinates (
lonlat
), and unnests these fields.Converts MUSIC bearings to geographic bearings using the associated Antenna Pattern Matrix (APM) object.
Computes additional metrics such as signal power in dB, signal-to-noise ratio (SNR), and DOA peak response in dB.
Appends the timestamp to the table and reorders columns for clarity.
Value
A data frame with the following columns:
-
datetime
: Timestamp of the data. -
longitude
: Geographic longitude of the detection. -
latitude
: Geographic latitude of the detection. -
range_cell
: Range cell number. -
range
: Range in kilometers. -
doppler_bin
: Doppler bin number. -
doppler_freq
: Doppler frequency. -
radial_velocity
: Radial velocity in m/s. -
signal_power
: Signal power. -
bearing
: Geographic bearing in degrees. -
bearing_raw
: Original MUSIC bearing in degrees. -
noise_level
: Noise level in dB. -
signal_power_db
: Signal power in dB. -
SNR
: Signal-to-noise ratio in dB. -
DOA_peak_resp_db
: DOA peak response in dB.
See Also
Examples
# Load sample CSS and APM files
cs_file <- system.file("css_data/CSS_TORA_24_04_04_0700.cs", package = "SeaSondeR")
apm_file <- system.file("css_data/MeasPattern.txt", package = "SeaSondeR")
apm_obj <- seasonder_readSeaSondeRAPMFile(apm_file)
# Create SeaSondeRCS object with APM
cs_obj <- seasonder_createSeaSondeRCS(cs_file, seasonder_apm_object = apm_obj)
FOR <- seasonder_getSeaSondeRCS_FOR(cs_obj)
cs_obj <- seasonder_setSeaSondeRCS_FOR(cs_obj,FOR[4:5])
# Run MUSIC algorithm (in FOR context) if MUSIC data is available:
cs_obj <- seasonder_runMUSICInFOR(cs_obj)
# Export MUSIC table
music_table <- seasonder_exportMUSICTable(cs_obj)
print(music_table)