2.0.9 ā€¢ Published 2 years ago

@ifct2017/hierarchy v2.0.9

Weekly downloads
2
License
MIT
Repository
github
Last release
2 years ago

Tree-like hierarchy of nutrients, and its components. šŸ“¦ Node.js, šŸ“œ Files.

This is part of package ifct2017. Online database: ifct2017.github.io.

const hierarchy = require('@ifct2017/hierarchy');
// hierarchy(query)
// ā†’ {parents, ancestry, children} if found, null otherwise


hierarchy('soluble oxalic acid');
hierarchy('Soluble Oxalic Acid');
// { parents: 'oxalt', ancestry: 'oxalt orgac', children: '' }

hierarchy('what is hierarchy of total saturated fat?');
hierarchy('who are children of total saturated fat?');
// { parents: 'fatce',
//   ancestry: 'fatce',
//   children:
//    'f4d0 f6d0 f8d0 f10d0 f11d0 f12d0 f14d0 f15d0 f16d0 f18d0 f20d0 f22d0 f24d0' }
hierarchy.load() // ā†’ corpus
hierarchy.sql([table], [options]) // ā†’ sql statements
hierarchy.csv() // ā†’ path of csv file

npm.io ORG DOI

Data was obtained from the book Indian Food Composition Tables 2017. Food composition values were measured by National Institute of Nutrition, Hyderabad. Take a peek at the raw data here: Document, Webpage.

2.0.9

2 years ago

2.0.8

2 years ago

2.0.2

3 years ago

2.0.5

3 years ago

2.0.1

3 years ago

2.0.0

3 years ago

1.2.7

4 years ago

1.2.6

4 years ago

1.2.5

4 years ago

1.2.4

4 years ago

1.2.3

4 years ago

1.2.2

6 years ago

1.2.1

6 years ago

1.2.0

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago