> For the complete documentation index, see [llms.txt](https://time-series-features.gitbook.io/hctsa-manual/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://time-series-features.gitbook.io/hctsa-manual/installing-and-using-hctsa/analyzing_visualizing/feature_summary.md).

# Investigating specific operations

Sometimes it's useful to be able to investigate the behavior of an individual operation (or feature) across a time-series dataset. What are the distribution of outputs, and what types of time series receive low values, and what receive high values?

These types of simple questions for specific features of interest can be investigated using the `TS_FeatureSummary` function. The function takes in an operation ID as its input (and can also take inputs specifying a custom data source, or custom annotation parameters), and produces a distribution of outputs from that operation across the dataset, with the ability to then annotate time series onto that plot.

For example, the following:

```
TS_FeatureSummary(100)
```

Produces the following plot (where 6 points on the distribution have been clicked on to annotate them with short time-series segments):

![](/files/-LEJvoog8CKOCr-VFIRJ)

You can visually see that time series with more autocorrelated patterns through time receive higher values from this operation. Because groups have not been assigned to this dataset, the time series are colored at random.

Running TS\_FeatureSummary in violin plot mode provides another representation of the same result:

```
annotateParams = struct('maxL',500);
TS_FeatureSummary(4310,'raw',true,annotateParams);
```

This plots the distribution of feature 4310 from `HCTSA.mat` as a violin plot, with ten 500-point time series subsegments annotated at different points through the distribution, shown to the right of the plot:

![](/files/-LEJvoosNxvT-QzEabWT)

## Plotting for labeled groups of time series

When time series groups have been labeled (using [`TS_LabelGroups`](/hctsa-manual/installing-and-using-hctsa/analyzing_visualizing/grouping.md) as: `TS_LabelGroups({'seizure','eyesOpen','eyesClosed'},'raw');`), `TS_FeatureSummary` will plot the distribution for each class separately, as well as an overall distribution. Annotated points can then be added to each class-specific distributions. In the example shown below, we can see that the 'noisy' class (red) has low values for this feature (`CO_tc3_2_denom`), whereas the 'periodic' class mostly has high values.

![](/files/-LEJvooy6e6RinkXYbrS)

## Simpler distributions

`TS_SingleFeature` provides a simpler way of seeing the class distributions without annotations, as either kernel-smoothed distributions, as in `TS_FeatureSummary`, or as violin plots.\
See below for example implementations:

```
opID = 500;
makeViolin = false;
TS_SingleFeature('raw',opID,makeViolin);
```

Shows the distributions with classification bar underneath (for where a linear classifier would classify different parts of the space as either noisy or periodic):

![](/files/-LEJvop1Op-wgAMxEr7L)

```
opID = 500;
makeViolin = true;
TS_SingleFeature('raw',opID,makeViolin);
```

Shows the distributions shown as a violin plot, with means annotated and classification bar to the left:

![](/files/-LEJvopBUTHA7ED9ED-8)

Note that the title, which gives an indication of the 10-fold cross-validated balanced accuracy of a linear classifier in the space is done on the basis of a single 10-fold split and is stochastic. Thus, as shown above, this can yield slightly different results when repeated. For a more rigorous analysis than this simple indication, the procedure should be repeated many more times to give a converged estimate of the balanced classification accuracy.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://time-series-features.gitbook.io/hctsa-manual/installing-and-using-hctsa/analyzing_visualizing/feature_summary.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
