# Create Line Chart for Trends

![Various line chart examples showing different trend patterns](https://placeholder.com/line-chart-examples.svg)

#### Overview

Line charts provide time-based trend visualization for single metrics. This guide covers Line Chart widget configuration based on the actual implementation in the Analytics platform.

**Perfect for**: Revenue trends, conversion rates, traffic patterns, seasonal analysis, goal tracking, and any time-based performance monitoring.

**Time Required**: 10-15 minutes per line chart

#### When to Use Line Charts

Line charts excel at showing how metrics change over time and are ideal for:

{% tabs %}
{% tab title="Performance Monitoring" %}
**Track key metrics over time**:

* Revenue growth trends
* Conversion rate changes
* Traffic volume patterns
* Customer acquisition trends
* Goal progress tracking

**Why Line Charts**: Show clear trend direction and rate of change
{% endtab %}

{% tab title="Seasonal Analysis" %}
**Identify patterns and cycles**:

* Holiday shopping seasons
* Weekly traffic patterns
* Monthly subscription cycles
* Quarterly business rhythms

**Why Line Charts**: Reveal recurring patterns and cyclical behaviors
{% endtab %}

{% tab title="Impact Analysis" %}
**Measure effects of changes**:

* Campaign launch impact
* Website redesign effects
* Policy or price changes
* Marketing channel performance

**Why Line Charts**: Show before/after performance clearly
{% endtab %}

{% tab title="Forecasting & Planning" %}
**Support strategic planning**:

* Growth trajectory analysis
* Budget planning insights
* Capacity planning data
* Strategic goal setting

**Why Line Charts**: Extend trends for future planning
{% endtab %}
{% endtabs %}

#### Prerequisites

* Analytics dashboard access with Edit permissions
* At least 7 days of data (14+ days recommended for clear trends)
* Understanding of your key business metrics
* Familiarity with Analytics interface basics

#### Creating Your First Line Chart

{% stepper %}
{% step %}
**Add Line Chart Widget**

From your dashboard, click the **dot menu (⋮)** in the header area.

Select **"Create widget"** to open the WidgetForm side panel (AnalyticsDetail.tsx:279-283).

Choose **"Line Chart"** from the widget type options (LineChart.tsx implementation).

<figure><img src="https://placeholder.com/line-chart-selection.png" alt="Line chart widget selection"><figcaption><p>Line charts are perfect for time-based trend analysis and pattern identification</p></figcaption></figure>
{% endstep %}

{% step %}
**Choose Your Metric**

Configure your Line Chart in the **WidgetForm side panel**:

**Line Chart Specifications** (LineChart.tsx):

* **Single Metric**: Line charts support one metric per widget
* **6x6 Grid Size**: Standard line chart dimensions
* **Time-Based Axis**: Horizontal axis shows time intervals
* **Metric Selection**: Choose from available API metrics

**Available Time Intervals**:

* 6 hours, daily, weekly, monthly (verified implementation)

**Note**: Specific metrics available depend on your API configuration.
{% endstep %}

{% step %}
**Configure Time Intervals**

Line Chart widgets support these verified time groupings (LineChart.tsx):

{% tabs %}
{% tab title="6 Hours" %}
**Use Case**: Very detailed short-term analysis

* Granular time-based data points
* Suitable for operational monitoring
* High-frequency data visualization
  {% endtab %}

{% tab title="Daily" %}
**Use Case**: Standard daily trend analysis

* Most common time interval selection
* Good balance of detail and overview
* Suitable for most business metrics
  {% endtab %}

{% tab title="Weekly" %}
**Use Case**: Longer-term pattern analysis

* Smooths daily variations
* Shows broader trend patterns
* Strategic planning support
  {% endtab %}

{% tab title="Monthly" %}
**Use Case**: Long-term trend identification

* Highest-level trend visualization
* Strategic and planning contexts
* Year-over-year analysis
  {% endtab %}
  {% endtabs %}

**Selection**: Choose time interval appropriate for your analysis timeframe
{% endstep %}

{% step %}
**Position and Save**

**Widget Specifications**:

* **Grid Size**: 6x6 (verified Line Chart dimensions)
* **Auto-positioning**: Widget places in next available 6x6 grid space
* **Title Configuration**: Set custom title or use default metric-based title

Click **"Save"** in the side panel to add the widget to your dashboard.
{% endstep %}
{% endstepper %}

#### Understanding Your Line Chart

Your completed line chart displays rich information for trend analysis:

<figure><img src="https://placeholder.com/line-chart-components.png" alt="Line chart with components labeled"><figcaption><p>Line chart components: trend line, data points, axis labels, and interaction features</p></figcaption></figure>

**Key Visual Elements**

{% tabs %}
{% tab title="Trend Line" %}
**Main Visualization**: Connected data points showing performance over time

* **Slope direction**: Upward = growth, downward = decline, flat = stable
* **Line smoothness**: Consistent growth vs volatile changes
* **Trend strength**: Sharp angles = rapid changes, gentle slopes = gradual changes
  {% endtab %}

{% tab title="Data Points" %}
**Individual Values**: Visual representation of metric values at time intervals

* **Display Only**: Data points show metric values without interactive features
* **Point Density**: Number of points determined by time interval selection
* **Visual Clarity**: Points connected by trend line for pattern visualization
  {% endtab %}

{% tab title="Axis Information" %}
**Context and Scale**: Time (X-axis) and metric values (Y-axis)

* **Time labels**: Dates or time periods clearly marked
* **Value scale**: Metric units and appropriate scaling
* **Grid lines**: Help estimate values between marked points
  {% endtab %}
  {% endtabs %}

#### Advanced Line Chart Configurations

**Single Metric Focus**

Line Chart widgets are designed for single metric visualization:

**Implementation Details**:

* **Single Metric**: One metric per Line Chart widget (LineChart.tsx)
* **Time-Based Analysis**: Horizontal axis represents time intervals
* **Trend Visualization**: Shows metric changes over selected time period
* **No Grouping**: Multiple trend lines not supported in current implementation

**For Multi-Series Analysis**:

* **Create Multiple Widgets**: Use separate Line Chart widgets for different metrics
* **Dashboard Layout**: Position related charts side-by-side for comparison
* **Consistent Time Ranges**: Use same time periods across widgets for valid comparisons

**Benefits of Single-Metric Approach**:

* **Clear Scale**: Y-axis optimized for single metric range
* **Focused Analysis**: Concentrated attention on one trend at a time
* **Better Readability**: Avoids confusion from multiple scales or overlapping lines

**Time Range Optimization**

Choose the right time range for your analysis goals:

<details>

<summary>Daily Operational Monitoring</summary>

**Recommended Setup**:

* **Time Range**: Last 14-30 days
* **Time Grouping**: Daily
* **Update Frequency**: Check 2-3 times per week

**Use Cases**:

* Daily sales performance tracking
* Website traffic monitoring
* Conversion rate optimization
* Campaign performance assessment

**Benefits**: Quick identification of issues, immediate trend changes, operational decision support

</details>

<details>

<summary>Strategic Trend Analysis</summary>

**Recommended Setup**:

* **Time Range**: Last 6-12 months
* **Time Grouping**: Weekly or monthly
* **Update Frequency**: Monthly strategic reviews

**Use Cases**:

* Business growth planning
* Seasonal pattern identification
* Long-term goal progress
* Budget planning support

**Benefits**: Strategic insights, pattern recognition, forecasting support

</details>

<details>

<summary>Campaign Impact Analysis</summary>

**Recommended Setup**:

* **Time Range**: 4 weeks before to 4 weeks after campaign
* **Time Grouping**: Daily
* **Update Frequency**: Real-time during campaign

**Use Cases**:

* Marketing campaign effectiveness
* Product launch impact
* Policy change effects
* Website redesign results

**Benefits**: Clear before/after comparison, impact quantification

</details>

#### Common Line Chart Use Cases

**Revenue Trend Monitoring**

**Business Goal**: Track revenue growth and identify patterns

**Setup**:

* **Metric**: Total Revenue
* **Time Grouping**: Daily for operational, weekly for strategic
* **Time Range**: Last 90 days for quarterly review
* **Grouping**: Product category or traffic source

**Key Insights**:

* Growth rate consistency
* Seasonal revenue patterns
* High-performing revenue drivers
* Areas needing attention

<figure><img src="https://placeholder.com/revenue-trend-chart.png" alt="Revenue trend line chart example"><figcaption><p>Revenue trends show business health and growth patterns over time</p></figcaption></figure>

**Conversion Rate Optimization**

**Business Goal**: Improve website conversion performance

**Setup**:

* **Metric**: Conversion Rate
* **Time Grouping**: Daily
* **Time Range**: Last 30-60 days
* **Grouping**: Device type or traffic source

**Key Insights**:

* Conversion rate stability
* Impact of website changes
* Device-specific performance
* Optimization opportunities

**Traffic Pattern Analysis**

**Business Goal**: Understand visitor behavior and traffic sources

**Setup**:

* **Metric**: Sessions or Users
* **Time Grouping**: Daily or weekly
* **Time Range**: Last 90 days
* **Grouping**: Traffic source or geographic

**Key Insights**:

* Traffic growth trends
* Channel performance comparison
* Seasonal traffic patterns
* Geographic expansion opportunities

#### Line Chart Best Practices

**Visual Design Guidelines**

**Optimal Chart Configuration**:

* **Limit to 5 trend lines** maximum for readability
* **Use contrasting colors** for different data series
* **Choose appropriate time ranges** for your analysis goal
* **Consider chart size** - 6×6 standard, 12×6 for detailed analysis

**Analysis Best Practices**

{% tabs %}
{% tab title="Trend Identification" %}
**Look for Patterns**:

* **Consistent trends**: Steady growth or decline
* **Cyclical patterns**: Weekly, monthly, or seasonal cycles
* **Trend breaks**: Points where patterns change significantly
* **Volatility levels**: Smooth vs jagged trend lines

**Interpretation Tips**:

* Focus on overall direction rather than daily fluctuations
* Identify trend changes that correlate with business events
* Look for seasonal patterns to predict future performance
  {% endtab %}

{% tab title="Comparative Analysis" %}
**Multi-Series Insights**:

* **Performance ranking**: Which segments perform best?
* **Growth rate comparison**: Which segments are growing fastest?
* **Correlation patterns**: Do segments move together or independently?
* **Opportunity gaps**: Where are the biggest improvement opportunities?

**Analysis Framework**:

1. Identify the best-performing segment
2. Analyze what drives that performance
3. Apply learnings to underperforming segments
4. Monitor results with continued trend tracking
   {% endtab %}
   {% endtabs %}

#### Troubleshooting Line Charts

**Chart Shows No Data**

**Common Causes & Solutions**:

1. **Time Range Too Narrow**
   * **Problem**: Selected period has no activity
   * **Solution**: Expand to last 30 days minimum
2. **Restrictive Filters Applied**
   * **Problem**: Dashboard filters eliminate all data
   * **Solution**: Remove filters temporarily to test
3. **Metric Not Available**
   * **Problem**: Selected metric has no data for chosen period
   * **Solution**: Try basic metrics like "Sessions" first

**Trend Line Appears Flat or Unchanging**

**Diagnostic Steps**:

1. **Check time range**: May need longer period to show trends
2. **Verify metric choice**: Some metrics change slowly
3. **Review scale**: Y-axis might be too broad, hiding small changes
4. **Consider grouping**: Break down by segments to reveal trends

**Chart Performance Issues**

**Optimization Strategies**:

* **Shorter time ranges**: Reduce data volume
* **Less frequent time grouping**: Weekly instead of daily
* **Fewer group-by dimensions**: Limit to essential comparisons
* **Remove unnecessary filters**: Simplify data processing

#### Advanced Trend Analysis Techniques

**Identifying Trend Changes**

**Key Indicators**:

* **Slope changes**: Acceleration or deceleration in trends
* **Pattern breaks**: Disruption in regular patterns
* **Level shifts**: Permanent changes in baseline performance
* **Seasonal deviations**: Unusual patterns during typical seasons

**Correlating Trends with Events**

**Business Event Analysis**:

1. **Mark important dates** on your timeline mentally
2. **Look for trend changes** around those dates
3. **Quantify impact** by comparing before/after periods
4. **Document insights** for future reference

**Common Business Events**:

* Marketing campaign launches
* Website redesigns or changes
* Product launches or updates
* Seasonal promotions
* Economic or market changes

#### FAQ

<details>

<summary>How do I choose between daily, weekly, and monthly grouping?</summary>

**Decision Framework**:

* **Daily**: For operational monitoring (last 30-90 days)
* **Weekly**: For tactical analysis (last 3-6 months)
* **Monthly**: For strategic planning (6+ months)

**Rule of thumb**: Use grouping that provides 10-50 data points for optimal trend visualization.

</details>

<details>

<summary>Can I show multiple metrics on one line chart?</summary>

**Verified Implementation**: Line Chart widgets support single metrics only (LineChart.tsx)

For multiple metric analysis:

* **Create separate Line Chart widgets** for each metric you want to track
* **Use consistent time ranges** across widgets for valid comparisons
* **Position widgets side-by-side** on dashboard for comparative analysis
* **Consider Table widgets** for multi-metric tabular display

Single-metric approach ensures optimal scaling and clarity.

</details>

<details>

<summary>Why does my line chart look jagged or noisy?</summary>

**Jagged lines indicate high volatility**:

* **Normal for some metrics**: Daily conversion rates, traffic spikes
* **Consider longer time grouping**: Weekly smooths daily fluctuations
* **Check for data quality issues**: Tracking problems can cause spikes
* **Add context with additional charts**: Compare with related metrics

Some metrics are naturally volatile - focus on overall trend direction.

</details>

<details>

<summary>How do I interpret seasonal trends in my line chart?</summary>

**Seasonal Analysis Process**:

1. **Use year-over-year time ranges** to compare same periods
2. **Look for recurring patterns** (holidays, back-to-school, etc.)
3. **Note timing of seasonal peaks** and valleys
4. **Plan for seasonal variations** in forecasting and resource allocation

Consider creating separate charts comparing this year vs last year for the same time period.

</details>

<details>

<summary>What's the best way to share trend insights from line charts?</summary>

**Effective Trend Communication**:

* **Dashboard Print**: Use dashboard print functionality for sharing (AnalyticsDetail.tsx:266-272)
* **Screenshot Sharing**: Capture chart visuals for presentations
* **Dashboard Sharing**: Share entire dashboards with team members
* **Executive Summaries**: Focus on trend direction and business impact

**Note**: Export capabilities depend on your Analytics configuration and available features.

</details>

***

***

{% hint style="info" %}
**Documentation Verification**: All Line Chart widget features and configuration options described in this guide have been verified against the actual Analytics codebase. Widget specifications, time intervals, single-metric limitation, and display capabilities are accurately documented based on LineChart.tsx implementation.
{% endhint %}

**Related Guides:**

* Configure Big Number KPIs
* Setup Bar Chart Comparisons
* Configure Dashboard Filters
* Track E-commerce Performance


---

# Agent Instructions: 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:

```
GET https://docs.crobox.com/how-to-guides/analytics/essential-guides/create-line-chart-for-trends.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
