load_harplus {HARplus} | R Documentation |
Load and Process GEMPACK HAR Files (Internal)
Description
Reads a GEMPACK HAR file and efficiently extracts structured data while maintaining compatibility with standard HAR formats. This implementation builds upon the foundational work of the HARr package, reorganizing the process for improved execution speed, memory management, and handling of sparse data structures.
Usage
load_harplus(con, coefAsname = FALSE, lowercase = TRUE, select_header = NULL)
Arguments
con |
Character or connection. The file path to the HAR file or an open binary connection. |
coefAsname |
Logical. If |
lowercase |
Logical. If |
select_header |
Character vector. Specific headers to extract; if |
Details
-
Efficient File Reading: Reads large HAR files in chunks for better performance.
-
Optimized Memory Usage: Reduces unnecessary allocations and improves cleanup.
-
Streamlined Header Processing: Ensures accurate extraction of dimension metadata.
-
Supports Sparse Data Structures: Handles
RESPSE
andREFULL
headers efficiently.
Supported HAR Header Types:
-
1CFULL
: Character headers -
2IFULL
: Integer headers -
2RFULL
: Real headers -
REFULL
: Real headers with extended metadata -
RESPSE
: Sparse real headers
Value
A structured list where:
Each element corresponds to a header in the HAR file.
Names are either header names or coefficient names (if
coefAsname = TRUE
).Data maintains its original dimensions and attributes.
Author(s)
Pattawee Puangchit