Highly comparative time-series analysis with hctsa
  • Information about hctsa
    • Introduction
    • Getting started
    • Publications using hctsa
    • UMAP Projections
    • Related Time-Series Resources
    • List of included code files
    • FAQ
  • Installing and using hctsa
    • General advice and common pitfalls
    • Installing and setting up
      • Structure of the hctsa framework
      • Overview of an hctsa analysis
      • Compiling binaries
    • Running hctsa computations
      • Input files
      • Performing calculations
      • Inspecting errors
      • Working with hctsa files
    • Analyzing and visualizing results
      • Assigning group labels to data
      • Filtering and normalizing
      • Clustering rows and columns
      • Visualizing the data matrix
      • Plotting the time series
      • Low dimensional representation
      • Finding nearest neighbors
      • Investigating specific operations
      • Exploring classification accuracy
      • Finding informative features
      • Interpreting features
      • Comparing to existing features
      • Working with short time series
    • Working with a mySQL database
      • Setting up the mySQL database
      • The database structure
      • Populating the database with time series and operations
      • Adding time series
      • Retrieving from the database
      • Computing operations and writing back to the database
      • Cycling through computations using runscripts
      • Clearing or removing data
      • Retrieving data from the database
      • Error handling and maintenance
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Installing and using hctsa
  2. Working with a mySQL database

Retrieving from the database

PreviousAdding time seriesNextComputing operations and writing back to the database

Last updated 4 years ago

Was this helpful?

Retrieving data from the Results table of the database is typically done for one of two purposes:

  1. To calculate as-yet uncalculated entries to be stored back into the database, and

  2. To analyze already-computed data stored in the database in Matlab.

The function SQL_Retrieve performs both of these functions, using different inputs. Here we describe the use of the SQL_Retrieve function for the purposes of populating uncalculated (NULL) entries in the Results table of the database in Matlab.

For calculating missing entries in the database, SQL_Retrieve can be run as follows:

    SQL_Retrieve(ts_ids, op_ids, 'null');

The third input, 'null', retrieves ts_ids and op_ids from the sets provided that contain (as-yet) uncalculated (i.e., NULL) elements in the database; these can then be calculated and stored back in the database. An example usage is given below:

    SQL_Retrieve(1:5, 'all', 'null');

Running this code will retrieve null (uncalculated) data from the database for time series with ts_ids between 1 and 5 (inclusive) and all operations in the database, keeping only the rows and columns of the resulting time series x operations matrix that contain NULLs.

When calculations are complete and one wishes to analyze all of the data stored in the database (not just NULL entries requiring computation), the third input should be set to ‘all’ to retrieve all entries in the Results table of the database, as described .

SQL_Retrieve writes to a local Matlab file, HCTSA.mat, that contains the data retrieved from the database.

later