Close
Close window
YAML - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Mozilla Firefox.
Maplesoft logo
Maplesoft logo

Online Help

All Products Maple MapleSim


[フレーム] [フレーム]

YAML (.yml, .yaml) File Format

YAML file format

Description

YAML (YAML Ain't Markup Language) is a lightweight text-based data standard for describing structured data.

As a human-readable format, it offers an alternative to explicitly tagged structured data such as XML. The JSON format is a subset of YAML 1.2.

The YAML package provides tools for parsing and generating YAML expressions.

The general-purpose commands Import and Export also support this format.

Examples

Parse a YAML string as an expression.

>

YAML:-ParseString[1, 2, 3.265, 6.01, 7.373]

1,2,3.265,6.01,7.373

(1)

Import data from a file in YAML format.

>

Importexample/address.yaml,base=datadir

tablefounded=1988,companyName=Maplesoft,address=tablecountry=Canada,province=ON,postalCode=N2V 1K8,city=Waterloo,streetAddress=615 Kumpf Drive,phoneNumbers=tablenumber=+1 (519) 747-2373,type=local,tablenumber=+1 (800) 267-6583,type=toll-free,tablenumber=+1 (519) 747-5284,type=fax

(2)

Export data to a YAML file in the home directory of the current user.

>

MousetableGenus=Mus,Species=musculus

MousetableGenus=Mus,Species=musculus

(3)
>

MouseFamilyMuridae

MouseFamilyMuridae

(4)
>

MouseOrderRodentia

MouseOrderRodentia

(5)
>

MouseClassMammalia

MouseClassMammalia

(6)
>

Exportmouse.yaml,Mouse,base=homedir

80

(7)

References

YAML 1.2 Language Specification, http://www.yaml.org/spec/1.2/spec.html , yaml.org.


Download Help Document

AltStyle によって変換されたページ (->オリジナル) /