Giter Site home page Giter Site logo

ionio-illustrate's Introduction

The ionio-illustrate package

This package implements a Cetz chart-like object for displying mass spectrometric data in Typst documents. It allows for individually styled mass peaks, callouts, titles, and mass callipers.

Explore the docs »

Report Bug · Request Feature

Getting Started

To make use of the ionio-illustrate package, you'll need to add it to your project like shown below. Make sure you are importing a version that supports your end goal.

#import "@preview/ionio-illustrate:0.3.0": *

Then, load in your mass spectrum data and pass it through to the package like so. Data should be 2D array, and by default the mass-charge ratio is in the first column, and the relative intensities are in the second column.

#let data = csv("isobutelene_epoxide.csv")

#let ms = mass-spectrum(massspec, args: (
  size: (12,6),
  range: (0,100),
)) 

#figure((ms.display)())

There are many ways to further enhance your spectrum, please check out the manual to find out how.

(back to top)

Roadmap

  • Pass style options through to the plot (tracker: #1)
  • Better placement of text depending on plot size
  • Improve default step on axes
  • Add support for callouts that are not immediately above their assigned peak
    • Automatically detect when two annotations are too close, and display accordingly
  • Move to new Typst type system (waiting on upstream)
  • Add in function for displaying skeletal structure of chemical
  • Optional second axis for absolute intensity
  • Add additional display functions
    • Figure out function signature for multiple data sets
    • Overlayed and shifted
    • Horizontal reflection
      • How to update existing extras?

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE for more information.

(back to top)

Gallery

(back to top)

ionio-illustrate's People

Contributors

jamesrswift avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

ionio-illustrate's Issues

`dual-reflection` display mode

Tracking issue for dual display mode. Current objectives are:

  • Handle data input
  • Handle how axes are calculated
  • Handle plot-extra functions
    • Pass additional option, maybe automatically somehow? Store state on #ms?
    • Adjust labels to account for vertical space on reflected pane.
    • Adjust callipers

Style Tracker

This issue will track the progress towards allowing styling on the graph components using Cetz style dictionaries.

Tracking chart:

  • Styling for axes
  • Styling for all peaks
  • Styling for specific peaks
  • Styling for peak annotations
  • Styling for mass callipers

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.