Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Binning temporal data using the built-in _hours_ interval forces interval boundaries to start at midnight

オープン
#2,452 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
52/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
静か
技術スタック
javascript

調査の方向性

まず、提供された Plot.plot の呼び出しを再現し、示されている2日間にわたる11時間ビニングを比較します。Plot.binY が使用する組み込みの時間間隔処理を追跡します。完了条件は、最後に部分的なビンが生じる可能性を除き、連続するビンが午前0時にリセットされるのではなく、11時間幅を維持することです。

索引モデルが issue の本文から書いたものです。

説明

bug

Consider the following plot invocation. Every hour there’s an event and I’m trying to bin them in intervals of 11 hours each.

Plot.plot({
  color: { legend: true, transform: null },
  marks: [
    Plot.barY(
      Array.from({length: 48}, (_, i) => (new Date(2026, 7, 1 + Math.floor(i / 24), i%24))),
      Plot.binY({fill: 'count'}, {y: { interval: '11 hours'}})
    )
  ]
})
Image

I expected each bin to be the same size (maybe expect the very last one). Instead each day is individually divided into two bins of size 11 hours and one bin of size 2 hours.

The same happens for every interval of which 24 hours isn’t an integer multiple (i.e., 5, 7, 9, …).

This might be related to https://github.com/observablehq/plot/discussions/2450

主要言語
HTML
スター
5.4k
フォーク
246
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

observablehq/plot のほかの issue

observablehq/plot の issue をすべて見る

似ている issue

Data Visualization の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。