Did you know ... Search Documentation:
Packs (add-ons) for SWI-Prolog

Package "quantity"

Title:Parse quantities like "1.5 kg" and return some formatting information.
Rating:Not rated. Create the first rating!
Latest version:0.1
SHA1 sum:f56ae704fd428d36a526b04ced2b7db775ff8acf
Author:Matthias Gondan <Matthias.Gondan@psy.ku.dk>

Reviews

No reviews. Create the first review!.

Details by download location

VersionSHA1#DownloadsURL
0.1b9fc30a93d3a348b28b3c48fb050b6228915a7b51https://github.com/mgondan/quantity.git
de0c372d749a07bae015990d9f8de43cb2e4e0161https://github.com/mgondan/quantity.git
f56ae704fd428d36a526b04ced2b7db775ff8acf1https://github.com/mgondan/quantity.git

quantity

Prolog package to parse quantities such as "1.5 kg" or "1E-10" or "p < .001". Its main purpose is give feedback to users of an e-learning system to provide numeric input in the correct format (e.g., t-ratios with 2 decimal places).

You can find a SWISH demo here, https://swish.swi-prolog.org/p/quantity-0.1.swinb

Installation and usage

Simple usage example from the SWI-Prolog console:

pack_install(quantity).
use_module(library(quantity)).

quantity("1.5 kg", Number, Options).

For more examples, type "ex_quant."

Contents of pack "quantity"

Pack contains 4 files holding a total of 40.0K bytes.