-
-
Notifications
You must be signed in to change notification settings - Fork 0
Decision.EntropyWeights
Rodrigo Celso de Lima Porto edited this page Jan 13, 2026
·
1 revision
This function calculates the weights of decision criteria using the entropy weighting method. It analyzes the distribution of values across each criterion to determine their relative importance based on information entropy.
Decision.EntropyWeights(
tbl as table,
optional columnNames as {text}
) as record-
tbl: The input table containing numeric values for each criterion. -
columnNames(optional): A list of column names to include in the calculation. If not provided, all numeric columns in the table will be used.
- The entropy weighting method is a data-driven approach to determine the importance of each criterion based on its variability.
- The function performs the following steps:
- Normalization of each criterion using min-max scaling.
- Calculation of entropy for each criterion based on the normalized values.
- Computation of weights:
$w_{j}=\frac{1βs_{j}}{mβ\sum_{j=1}^{m}{s_{j}}}β$
- where:
-
$s_j$ β is the entropy of criterion$j$ , -
$m$ is the number of criteria.
-
- If all values in a column are equal, its entropy is the maximum and its weight is zero.
- If the table has only one row, all criteria receive equal weight.
Returns a record where each field name corresponds to a criterion and each field value is the calculated weight.
Example 1: Entropy weights for all numeric columns. Weights are assigned based on the variability of each criterion.
let
Source = #table(type table
[Cost=number, Quality=number, Speed=number], {
{300, 80, 60},
{250, 70, 75},
{400, 90, 50}
}),
Result = Decision.EntropyWeights(Source)
in
ResultResult
[Cost = 0.36, Quality = 0.31, Speed = 0.33]Example 2: Calculates entropy weights only for specified columns.
let
Source = #table(type table
[Cost=number, Quality=number, Speed=number], {
{300, 80, 60},
{250, 70, 75},
{400, 90, 50}
}),
Result = Decision.EntropyWeights(Source, {"Cost", "Speed"})
in
ResultResult
[Cost = 0.52, Speed = 0.48]- Binary.Unzip πβοΈ
- DateTime.ToUnixTime πβοΈ
- Decision.EntropyWeights πβοΈ
- Decision.TOPSIS πβοΈ
- List.Correlation πβοΈ
- List.Intercept πβοΈ
- List.Outliers πβοΈ
- List.PopulationStdDev πβοΈ
- List.Primes πβοΈ
- List.Rank πβοΈ
- List.Slope πβοΈ
- List.Variance πβοΈ
- List.WeightedAverage πβοΈ
- Number.FromRoman πβοΈ
- Number.IsInteger πβοΈ
- Number.IsPrime πβοΈ
- Number.ToRoman πβοΈ
- Statistical.NormDist πβοΈ
- Statistical.NormInv πβοΈ
- Table.AddColumnFromList πβοΈ
- Table.CorrelationMatrix πβοΈ
- Table.NormalizeColumnNames πβοΈ
- Table.NormalizeTextColumns πβοΈ
- Table.RemoveBlankColumns πβοΈ
- Table.TransposeCorrectly πβοΈ
- Text.CountChar πβοΈ
- Text.ExtractNumbers πβοΈ
- Text.HtmlToPlainText πβοΈ
- Text.RegexExtract πβοΈ
- Text.RegexReplace πβοΈ
- Text.RegexSplit πβοΈ
- Text.RegexTest πβοΈ
- Text.RemoveAccents πβοΈ
- Text.RemoveDoubleSpaces πβοΈ
- Text.RemoveLetters πβοΈ
- Text.RemoveNumerals πβοΈ
- Text.RemovePunctuations πβοΈ
- Text.RemoveStopwords πβοΈ
- Text.RemoveWeirdChars πβοΈ
- AreArraysEquals πβοΈ
- AutoFillFormulas πβοΈ
- CleanString πβοΈ
- DisableRefreshAll πβοΈ
- EnableRefreshAll πβοΈ
- FileExists πβοΈ
- FileNameIsValid πβοΈ
- GetAllFileNames πβοΈ
- GetLetters πβοΈ
- GetMonthNumberFromName πβοΈ
- GetStringBetween πβοΈ
- GetStringWithSubstringInArray πβοΈ
- GetTableColumnNames πβοΈ
- IsAllTrue πβοΈ
- IsInArray πβοΈ
- ListObjectExists πβοΈ
- PreviousMonthNumber πβοΈ
- RangeHasAnyFormula πβοΈ
- RangeHasConstantValues πβοΈ
- RangeIsHidden πβοΈ
- RangeToHtml πβοΈ
- SendEmail πβοΈ
- SetQueryFormula πβοΈ
- StringContains πβοΈ
- StringEndsWith πβοΈ
- StringStartsWith πβοΈ
- SubstringIsInArray πβοΈ
- Summation πβοΈ
- TableHasQuery πβοΈ
- WorksheetHasListObject πβοΈ