"PercentFraction" (Interpreter Type)
Percentage expressed in natural language.
Details
- "PercentFraction" can be used in Interpreter and related constructs, including deployed smart form fields.
- Use of "PercentFraction" requires connectivity to the Wolfram Cloud.
- When the input is a unitless number, "PercentFraction" converts it to a percentage.
Allowed Forms
- All the natural-language numbers allowed by "SemanticNumber" are supported for the quantity magnitude.
- The unit can be expressed in natural language or via abbreviations or symbols.
Restriction Specifications
-
Restricted["PercentFraction",{{choices1,…}}] one among choices Restricted["PercentFraction", quantity] a quantity considered as a fraction of the baseline quantity
Interpretation
- "PercentFraction" yields a Quantity.
Examples
Basic Examples (3)Summary of the most common use cases
In[1]:=1

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-fgnq4t
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-u6fcfh
Out[2]=2

If no unit is provided, convert the number to a percentage:
In[1]:=1

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-rae2nv
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-p83p1r
Out[2]=2

In[3]:=3

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-1j8ndf
Out[3]=3

In[4]:=4

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-7ubsf8
Out[4]=4

Cf. "Percent", which simply infers a percent unit:
In[5]:=5

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-h3nnba
Out[5]=5

And "HeuristicPercent", which decides what to do based on heuristics:
In[6]:=6

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-71rswb
Out[6]=6

In[7]:=7

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-0fth1x
Out[7]=7

Interpret quantities or numbers as fractions of the given baseline:
In[1]:=1

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-q60te8
Out[1]=1

In[2]:=2

✖
https://wolfram.com/xid/0br8dru3e1b5n4k5iufcdiv2-vn07p0
Out[2]=2
