Activity Graph

by rwyattwalker
5
4
3
2
1
Score: 35/100

Description

This plugin has not been manually reviewed by Obsidian staff. Render activity heatmaps from Dataview query results.

Reviews

No reviews yet.

Stats

stars
79
downloads
0
forks
1
days
NaN
days
NaN
days
0
total PRs
0
open PRs
0
closed PRs
0
merged PRs
0
total issues
0
open issues
0
closed issues
0
commits

Latest Version

Invalid date

Changelog

README file from

Github

Activity Graph

Render a GitHub-style activity heatmap from Dataview queries. Use Dataview queries directly with optional query level setting overrides.

Requirements

  • Obsidian
  • Dataview plugin enabled

Basic usage

Use an activity-graph code block containing a Dataview query:

TABLE file.day AS date, 1 AS value
FROM "Daily"
SORT file.day ASC

Query requirements

Your Dataview query must return:

  • date: a date value (Dataview date, file.day, or an ISO date string like YYYY-MM-DD)
  • value: a number (for intensity; use 1 for binary activity)

Examples

Count files (binary activity):

TABLE date(file.name) AS date, 1 AS value
FROM "Exercise Logs"

Track a numeric field:

TABLE file.day AS date, duration AS value
FROM "Exercise Logs"

Per-query overrides

Add a --- block after the query:

TABLE file.day AS date, duration AS value
FROM "Exercise Logs"

---
title: Exercise
daysToShow: 90
showLegend: false
colorGradient: purple
minValue: 0
maxValue: 3
lessLabel: 0
moreLabel: 3+

Supported overrides:

  • title
  • daysToShow
  • showMonthLabels
  • showWeekdayLabels
  • showLegend
  • startWeekOnMonday
  • colorGradient
  • lessLabel
  • moreLabel
  • minValue
  • maxValue

Notes

  • The graph ends on today's date (local time) and shows daysToShow days backwards.
  • Overrides are plain key: value lines following a ---.
  • Supported gradients: green, blue, purple, orange, red, plus any custom palettes you add in settings (default: green).
  • minValue/maxValue let you lock the heatmap scale; leave blank in settings (or omit in overrides) to keep it relative.
  • The following css snippet can be added to allow more space for the graph, can look squished otherwise:
    body {
    --file-line-width: 1000px;
    }
    

Upcoming Features

  • Custom date range (currently only supports today - X days)
  • If you have a desired feature, let me know!

Screenshots

Query

Result

Default Color Pallets

Green
Blue
Purple
Orange
Red