Excel MIN Function
The Excel MIN function returns the smallest value from a specified range of numeric values
Example: Excel MIN Function
=MIN(C5:C9)
|
Result in cell C10 (-7) - returns the smallest numeric value from the selected range.
|
=MIN(D5:D9)
|
Result in cell D10 (2) - returns the smallest numeric value from the selected range.
|
METHOD 2. Excel MIN function using the Excel built-in function library
EXCEL
Formulas tab > Function Library group > More Functions > Statistical > MIN > populate the input box
=MIN(C5:C9) Note: in this example we are populating an input box with a single range. |
Sub Excel_MIN_Function()
'declare a variable
Dim ws As Worksheet
Dim ws As Worksheet
Set ws = Worksheets("MIN")
'apply the Excel MIN function
ws.Range("C10") = Application.WorksheetFunction.Min(ws.Range("C5:C9"))
ws.Range("D10") = Application.WorksheetFunction.Min(ws.Range("D5:D9"))
ws.Range("C10") = Application.WorksheetFunction.Min(ws.Range("C5:C9"))
ws.Range("D10") = Application.WorksheetFunction.Min(ws.Range("D5:D9"))
End Sub
OBJECTS
Worksheets: The Worksheets object represents all of the worksheets in a workbook, excluding chart sheets.
Range: The Range object is a representation of a single cell or a range of cells in a worksheet.
Worksheets: The Worksheets object represents all of the worksheets in a workbook, excluding chart sheets.
Range: The Range object is a representation of a single cell or a range of cells in a worksheet.
PREREQUISITES
Worksheet Name: Have a worksheet named MIN.
Worksheet Name: Have a worksheet named MIN.
ADJUSTABLE PARAMETERS
Output Range: Select the output range by changing the Range references ("C10") and ("D10") in the VBA code to any cell in the worksheet, that doesn't conflict with the formula.
DESCRIPTION
The Excel MIN function returns the smallest value from a specified range of numeric values.
The Excel MIN function returns the smallest value from a specified range of numeric values.
SYNTAX
=MIN(number1, [number2], ...)
=MIN(number1, [number2], ...)
ARGUMENT(S)
number1: (Required) A single numeric cell or a range of numeric cells.
number2: (Optional) A single numeric cell or a range of numeric cells.
number1: (Required) A single numeric cell or a range of numeric cells.
number2: (Optional) A single numeric cell or a range of numeric cells.
ADDITIONAL NOTES
Note 1: In Excel 2007 and later the MIN function can accept up to 255 number arguments. In Excel 2003 the MIN function can only accept up to 30 number arguments.