MinMax

MinMax[list]

gives the list {Min[list],Max[list]}.

MinMax[list,δ]

gives {Min[list]-δ, Max[list]+δ}.

MinMax[list,Scaled[s]]

gives {Min[list]-δ, Max[list]+δ} where δ=s×(Max[list]-Min[list]).

MinMax[list,{δmin,δmax}]

gives {Min[list]-δmin,Max[list]+δmax}.

Details

  • MinMax yields a definite result if all its arguments are real numbers.
  • In other cases, MinMax carries out some simplifications.
  • MinMax[list,] flattens out all sublists in list.
  • MinMax[{}] gives {Infinity,-Infinity}.

Examples

open allclose all

Basic Examples  (1)

Find the minimum and maximum of a list:

Pad by a fixed amount:

Pad by a fraction of the difference:

Scope  (1)

Find the minimum and maximum of a list:

Pad by a fixed amount:

Pad by a fraction of the difference:

Pad the minimum and maximum differently:

Generalizations & Extensions  (1)

When there are coordinates that are not numerical, the result is typically expressed in terms of Min and Max:

Properties & Relations  (3)

MinMax[list] is equivalent to {Min[list],Max[list]}:

In particular:

MinMax[list] is equivalent to Quantile[list,{0,1}]:

CoordinateBounds generalizes MinMax to higher dimension:

That corresponds to MinMax in each dimension:

Wolfram Research (2015), MinMax, Wolfram Language function, https://reference.wolfram.com/language/ref/MinMax.html.

Text

Wolfram Research (2015), MinMax, Wolfram Language function, https://reference.wolfram.com/language/ref/MinMax.html.

CMS

Wolfram Language. 2015. "MinMax." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/MinMax.html.

APA

Wolfram Language. (2015). MinMax. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/MinMax.html

BibTeX

@misc{reference.wolfram_2024_minmax, author="Wolfram Research", title="{MinMax}", year="2015", howpublished="\url{https://reference.wolfram.com/language/ref/MinMax.html}", note=[Accessed: 27-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_minmax, organization={Wolfram Research}, title={MinMax}, year={2015}, url={https://reference.wolfram.com/language/ref/MinMax.html}, note=[Accessed: 27-November-2024 ]}