bjpop / gurita

A convenient and expressive tool for data analytics and plotting on the command line
MIT License
6 stars 3 forks source link

Ability to add text annotations to plots #40

Open supernifty opened 2 years ago

supernifty commented 2 years ago

Included in this option would be the ability to set font attributes such as font size and colour.

bjpop commented 2 years ago

Thanks @supernifty.

One question is how should this feature be used on the command line? Each annotation needs a coordinate and some text and maybe some settings such as font. If there are a lot of them then it could be annoying to enter them.

One option might be to have a feature which works okay for a small number of annotations, where they are listed on the command line. And another option that would support a larger number of annotations that are derived from a table (input CSV etc). The latter might be nice to allow the data to generate the points. However, it probably would be best implemented if Hatch supported multiple tables. For instance you could either read in a table of annotations, or you could compute a new table of annotations on the fly and then use that. So maybe this latter feature is another good reason to support multiple tables. It might be worth thinking more about how that would work. In the meantime can probably easily implement something that works on the command line, if a bit tediously.