Tables & sources 6
-
fact_table · 23 step(s)
Plain-English steps
1. Load files from folder: FolderLocation 2. Remove columns: Extension, Date accessed, Date modified, Date created, Attributes, Folder Path, Name 3. Filter rows where [Attributes]?[Hidden]? <> true 4. Add calculated column: "Transform File" 5. Keep only columns: Transform File 6. Expand nested table column: "Transform File" 7. Set column types: Nomenclature (type), ReporterISO3 (type), ProductCode (Int64.Type), ReporterName (type), PartnerISO3 (type), PartnerName (type), Year (Int64.Type), TradeFlowName (type), TradeFlowCode (Int64.Type), TradeValue in 1000 USD (type) 8. Remove columns: Nomenclature, ReporterISO3, ReporterName, PartnerISO3, TradeFlowCode 9. Pivot column "TradeFlowName" with values from "TradeValue in 1000 USD" 10. Replace null with 0 in column "Export" 11. Replace null with 0 in column "Import" 12. Transform column "Export": _ * 1000 13. Transform column "Import": _ * 1000 14. Add calculated column: "Custom" 15. Set column types: Custom (type) 16. Remove columns: Year 17. Rename columns: Custom -> Date 18. Add calculated column: "TradeBalance" 19. Replace "Egypt, Arab Rep." with "Egypt" in column "PartnerName" 20. Replace "Ethiopia(excludes Eritrea)" with "Ethiopia" in column "PartnerName" 21. Replace "Korea, Rep." with "South Korea" in column "PartnerName" 22. Replace "Other Asia, nes" with "Taiwan" in column "PartnerName" 23. Replace "Slovak Republic" with "Slovakia" in column "PartnerName"
Original M query
let Source = Folder.Files(FolderLocation), #"Removed Columns" = Table.RemoveColumns(Source,{"Extension", "Date accessed", "Date modified", "Date created", "Attributes", "Folder Path", "Name"}), #"Filtered Hidden Files1" = Table.SelectRows(#"Removed Columns", each [Attributes]?[Hidden]? <> true), #"Invoke Custom Function1" = Table.AddColumn(#"Filtered Hidden Files1", "Transform File", each #"Transform File"([Content])), #"Removed Other Columns1" = Table.SelectColumns(#"Invoke Custom Function1", {"Transform File"}), #"Expanded Table Column1" = Table.ExpandTableColumn(#"Removed Other Columns1", "Transform File", Table.ColumnNames(#"Transform File"(#"Sample File"))), #"Changed Type" = Table.TransformColumnTypes(#"Expanded Table Column1",{{"Nomenclature", type text}, {"ReporterISO3", type text}, {"ProductCode", Int64.Type}, {"ReporterName", type text}, {"PartnerISO3", type text}, {"PartnerName", type text}, {"Year", Int64.Type}, {"TradeFlowName", type text}, {"TradeFlowCode", Int64.Type}, {"TradeValue in 1000 USD", type number}}), #"Removed Columns1" = Table.RemoveColumns(#"Changed Type",{"Nomenclature", "ReporterISO3", "ReporterName", "PartnerISO3", "TradeFlowCode"}), #"Pivoted Column" = Table.Pivot(#"Removed Columns1", List.Distinct(#"Removed Columns1"[TradeFlowName]), "TradeFlowName", "TradeValue in 1000 USD", List.Sum), #"Replaced Value" = Table.ReplaceValue(#"Pivoted Column",null,0,Replacer.ReplaceValue,{"Export"}), #"Replaced Value1" = Table.ReplaceValue(#"Replaced Value",null,0,Replacer.ReplaceValue,{"Import"}), #"Multiplied Column" = Table.TransformColumns(#"Replaced Value1", {{"Export", each _ * 1000, type number}}), #"Multiplied Column1" = Table.TransformColumns(#"Multiplied Column", {{"Import", each _ * 1000, type number}}), #"Added Custom" = Table.AddColumn(#"Multiplied Column1", "Custom", each Date.FromText("1/1/" & Text.From([Year]))), #"Changed Type1" = Table.TransformColumnTypes(#"Added Custom",{{"Custom", type date}}), #"Removed Columns2" = Table.RemoveColumns(#"Changed Type1",{"Year"}), #"Renamed Columns" = Table.RenameColumns(#"Removed Columns2",{{"Custom", "Date"}}), #"Added Custom1" = Table.AddColumn(#"Renamed Columns", "TradeBalance", each [Export]-[Import]), #"Replaced Value2" = Table.ReplaceValue(#"Added Custom1","Egypt, Arab Rep.","Egypt",Replacer.ReplaceText,{"PartnerName"}), #"Replaced Value3" = Table.ReplaceValue(#"Replaced Value2","Ethiopia(excludes Eritrea)","Ethiopia",Replacer.ReplaceText,{"PartnerName"}), #"Replaced Value4" = Table.ReplaceValue(#"Replaced Value3","Korea, Rep.","South Korea",Replacer.ReplaceText,{"PartnerName"}), #"Replaced Value5" = Table.ReplaceValue(#"Replaced Value4","Other Asia, nes","Taiwan",Replacer.ReplaceText,{"PartnerName"}), #"Replaced Value6" = Table.ReplaceValue(#"Replaced Value5","Slovak Republic","Slovakia",Replacer.ReplaceText,{"PartnerName"}) in #"Replaced Value6" -
dimSIC · 25 step(s)
Plain-English steps
1. Load Excel workbook: C:\Users\davidk\Desktop\writing\substack\trade\data\dimSIC.xlsx 2. Navigate to sheet/table: "Sheet1" 3. Promote first row to column headers 4. Set column types: NomenclatureCode (type), Tier (Int64.Type), ProductCode (type), ProductDescription (type), Column5 (type) 5. Remove columns: NomenclatureCode, Column5 6. Filter rows where ([Tier] = 3 or [Tier] = 4 7. Add calculated column: "3digit" 8. Add calculated column: "2digit" 9. Add calculated column: "1digit" 10. Merge/join tables (left outer) 11. Expand column "dim": ProductDescription, dim.ProductDescription 12. Rename columns: ProductDescription -> Product, dim.ProductDescription -> Segment 13. Remove columns: Tier, 3digit 14. Reorder columns 15. Merge/join tables (left outer) 16. Expand column "dim": ProductDescription, dim.ProductDescription 17. Rename columns: dim.ProductDescription -> Family 18. Reorder columns 19. Remove columns: 2digit 20. Merge/join tables (left outer) 21. Expand column "dim": ProductDescription, dim.ProductDescription 22. Remove columns: 1digit 23. Rename columns: Family -> Group, dim.ProductDescription -> Family 24. Reorder columns 25. Rename columns: Family -> Category
Original M query
let Source = Excel.Workbook(File.Contents("C:\Users\davidk\Desktop\writing\substack\trade\data\dimSIC.xlsx"), null, true), Sheet1_Sheet = Source{[Item="Sheet1",Kind="Sheet"]}[Data], #"Promoted Headers" = Table.PromoteHeaders(Sheet1_Sheet, [PromoteAllScalars=true]), #"Changed Type" = Table.TransformColumnTypes(#"Promoted Headers",{{"NomenclatureCode", type text}, {"Tier", Int64.Type}, {"ProductCode", type text}, {"ProductDescription", type text}, {"Column5", type any}}), #"Removed Columns" = Table.RemoveColumns(#"Changed Type",{"NomenclatureCode", "Column5"}), #"Filtered Rows" = Table.SelectRows(#"Removed Columns", each ([Tier] = 3 or [Tier] = 4)), #"Added Custom" = Table.AddColumn(#"Filtered Rows", "3digit", each Text.Start([ProductCode], 3)), #"Added Custom1" = Table.AddColumn(#"Added Custom", "2digit", each Text.Start([ProductCode], 2)), #"Added Custom2" = Table.AddColumn(#"Added Custom1", "1digit", each Text.Start([ProductCode], 1)), #"Merged Queries" = Table.NestedJoin(#"Added Custom2", {"3digit"}, #"DNU-SIC", {"ProductCode"}, "dim", JoinKind.LeftOuter), #"Expanded dim" = Table.ExpandTableColumn(#"Merged Queries", "dim", {"ProductDescription"}, {"dim.ProductDescription"}), #"Renamed Columns" = Table.RenameColumns(#"Expanded dim",{{"ProductDescription", "Product"}, {"dim.ProductDescription", "Segment"}}), #"Removed Columns1" = Table.RemoveColumns(#"Renamed Columns",{"Tier", "3digit"}), #"Reordered Columns" = Table.ReorderColumns(#"Removed Columns1",{"Product", "Segment", "2digit", "1digit"}), #"Merged Queries1" = Table.NestedJoin(#"Reordered Columns", {"2digit"}, #"DNU-SIC", {"ProductCode"}, "dim", JoinKind.LeftOuter), #"Expanded dim1" = Table.ExpandTableColumn(#"Merged Queries1", "dim", {"ProductDescription"}, {"dim.ProductDescription"}), #"Renamed Columns1" = Table.RenameColumns(#"Expanded dim1",{{"dim.ProductDescription", "Family"}}), #"Reordered Columns1" = Table.ReorderColumns(#"Renamed Columns1",{"Product", "Segment", "Family", "2digit", "1digit"}), #"Removed Columns2" = Table.RemoveColumns(#"Reordered Columns1",{"2digit"}), #"Merged Queries2" = Table.NestedJoin(#"Removed Columns2", {"1digit"}, #"DNU-SIC", {"ProductCode"}, "dim", JoinKind.LeftOuter), #"Expanded dim2" = Table.ExpandTableColumn(#"Merged Queries2", "dim", {"ProductDescription"}, {"dim.ProductDescription"}), #"Removed Columns3" = Table.RemoveColumns(#"Expanded dim2",{"1digit"}), #"Renamed Columns2" = Table.RenameColumns(#"Removed Columns3",{{"Family", "Group"}, {"dim.ProductDescription", "Family"}}), #"Reordered Columns2" = Table.ReorderColumns(#"Renamed Columns2",{"ProductCode", "Family", "Group", "Segment", "Product"}), #"Renamed Columns3" = Table.RenameColumns(#"Reordered Columns2",{{"Family", "Category"}}) in #"Renamed Columns3" -
DNU-SIC · 5 step(s)
Plain-English steps
1. Load Excel workbook: C:\Users\davidk\Desktop\writing\substack\trade\data\dimSIC.xlsx 2. Navigate to sheet/table: "Sheet1" 3. Promote first row to column headers 4. Set column types: NomenclatureCode (type), Tier (Int64.Type), ProductCode (type), ProductDescription (type), Column5 (type) 5. Remove columns: NomenclatureCode, Column5
Original M query
let Source = Excel.Workbook(File.Contents("C:\Users\davidk\Desktop\writing\substack\trade\data\dimSIC.xlsx"), null, true), Sheet1_Sheet = Source{[Item="Sheet1",Kind="Sheet"]}[Data], #"Promoted Headers" = Table.PromoteHeaders(Sheet1_Sheet, [PromoteAllScalars=true]), #"Changed Type" = Table.TransformColumnTypes(#"Promoted Headers",{{"NomenclatureCode", type text}, {"Tier", Int64.Type}, {"ProductCode", type text}, {"ProductDescription", type text}, {"Column5", type any}}), #"Removed Columns" = Table.RemoveColumns(#"Changed Type",{"NomenclatureCode", "Column5"}) in #"Removed Columns" -
dimGeo · 6 step(s)
Plain-English steps
1. Load CSV file: C:\Users\davidk\Desktop\writing\substack\trade\data\dimGeo.csv 2. Set column types: Column1 (type), Column2 (type), Column3 (type), Column4 (type) 3. Promote first row to column headers 4. Set column types: country (type), continent (type), sub_region (type), Trading Block (type) 5. Filter rows where ([continent] <> "" 6. Replace "" with "ROW" in column "Trading Block"
Original M query
let Source = Csv.Document(File.Contents("C:\Users\davidk\Desktop\writing\substack\trade\data\dimGeo.csv"),[Delimiter=",", Columns=4, Encoding=1252, QuoteStyle=QuoteStyle.None]), #"Changed Type" = Table.TransformColumnTypes(Source,{{"Column1", type text}, {"Column2", type text}, {"Column3", type text}, {"Column4", type text}}), #"Promoted Headers" = Table.PromoteHeaders(#"Changed Type", [PromoteAllScalars=true]), #"Changed Type1" = Table.TransformColumnTypes(#"Promoted Headers",{{"country", type text}, {"continent", type text}, {"sub_region", type text}, {"Trading Block", type text}}), #"Filtered Rows" = Table.SelectRows(#"Changed Type1", each ([continent] <> "")), #"Replaced Value" = Table.ReplaceValue(#"Filtered Rows","","ROW",Replacer.ReplaceValue,{"Trading Block"}) in #"Replaced Value" -
date_table · 1 step(s)
Plain-English steps
Generate a date calendar table
Original M query
ADDCOLUMNS( CALENDAR(MIN(fact_table[Date]), MAX(fact_table[Date])), "Year", YEAR([Date]), "MonthNum", MONTH([Date]), "Month", FORMAT([Date],"mmm"), "Month-Year", FORMAT([Date], "mmm yyyy"), "Sort Key", YEAR([Date])*100 + MONTH([Date]) ) -
MeasureTable · 2 step(s)
Plain-English steps
1. Create table from inline data 2. Set column types: Selection (type)
Original M query
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45W8swtyC8qKVaK1YlWcq1AsEOKElNSFZwScxLzklOVYmMB", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Selection = _t]), #"Changed Type" = Table.TransformColumnTypes(Source,{{"Selection", type text}}) in #"Changed Type"
Relationships 3
| From | To | Cardinality | Cross-filter |
|---|---|---|---|
| fact_table.ProductCode | dimSIC.ProductCode | Many-to-One | Single |
| fact_table.PartnerName | dimGeo.country | Many-to-One | Single |
| fact_table.Date | date_table.Date | Many-to-One | Single |
Measures 18
| Table | Name | Expression |
|---|---|---|
| MeasureTable | DynamicMeasure |
VAR MySelection = SELECTEDVALUE(MeasureTable[Selection])
VAR ReturnValue = SWITCH(
TRUE(),
MySelection = "Imports", SUM(fact_table[Import])
,MySelection = "Exports", SUM(fact_table[Export])
,MySelection = "Trade Balance", SUM(fact_table[TradeBalance])
)
RETURN ReturnValue |
| MeasureTable | Growth (Year) |
VAR DynMeasureCurrentYear = TOTALYTD(
[DynamicMeasure], date_table[Date]
)
VAR DynMeasurePrevYear = TOTALYTD(
[DynamicMeasure], DATEADD(date_table[Date], -1, YEAR)
)
VAR ReturnValue = DIVIDE((DynMeasureCurrentYear-DynMeasurePrevYear), DynMeasurePrevYear)
Return ReturnValue |
| MeasureTable | SpaceCraft Segment Recent Year |
CALCULATE(
[DynamicMeasure],
dimSIC[Segment] = "Spacecraft",
date_table[Year] = MAX(date_table[Year])
) |
| MeasureTable | Aircraft Segment Recent Year |
CALCULATE(
[DynamicMeasure],
SEARCH("Aircraft", dimSIC[Segment], 1, 0) > 0,
date_table[Year] = MAX(date_table[Year])
) |
| MeasureTable | TitleSpacecraftVisual | "SpaceCraft " & MIN(MeasureTable[Selection]) & " By Year Through " & MAX(date_table[Year]) |
| MeasureTable | TitleExports | "Exports: " & MAX(date_table[Year]) |
| MeasureTable | RecentImports | CALCULATE(
SUM(fact_table[Import]),
YEAR(date_table[Date]) = YEAR(MAX(date_table[Date]))
) |
| MeasureTable | RecentExports | CALCULATE(
SUM(fact_table[Export]),
YEAR(date_table[Date]) = YEAR(MAX(date_table[Date]))
) |
| MeasureTable | RecentTradeBalance | CALCULATE(
SUM(fact_table[TradeBalance]),
YEAR(date_table[Date]) = YEAR(MAX(date_table[Date]))
) |
| MeasureTable | TitleImports | "Imports: " & Max(date_table[Year]) |
| MeasureTable | TitleTradeBalance | "Trade Balance: " & Max(date_table[Year]) |
| MeasureTable | TitleGrowth | "1 Year Growth" |
| MeasureTable | TitleDynamicMeasure | MIN(MeasureTable[Selection]) |
| MeasureTable | TitleDynamicMeasureGrowth | MIN(MeasureTable[Selection]) & " Growth" |
| MeasureTable | Growth (3 Year) |
VAR DynMeasureCurrentYear = TOTALYTD(
[DynamicMeasure], date_table[Date]
)
VAR DynMeasurePrevYear = TOTALYTD(
[DynamicMeasure], DATEADD(date_table[Date], -3, YEAR)
)
VAR ReturnValue = DIVIDE((DynMeasureCurrentYear-DynMeasurePrevYear), DynMeasurePrevYear)/3
Return ReturnValue |
| MeasureTable | Title3Growth | "3 Year Growth" |
| MeasureTable | TitleDynamicMeasureWaterfallCategory | MIN(MeasureTable[Selection]) & " by Category" |
| MeasureTable | TitleDynamicMeasureWaterfall | MIN(MeasureTable[Selection]) & " By Trading Bloc" |
Columns 25
| Table | Column | Type | Expression |
|---|---|---|---|
| fact_table | ProductCode | regular | |
| fact_table | PartnerName | regular | |
| fact_table | Export | regular | |
| fact_table | Import | regular | |
| fact_table | Date | regular | |
| fact_table | TradeBalance | regular | |
| dimSIC | ProductCode | regular | |
| dimSIC | Category | regular | |
| dimSIC | Group | regular | |
| dimSIC | Segment | regular | |
| dimSIC | Product | regular | |
| DNU-SIC | Tier | regular | |
| DNU-SIC | ProductCode | regular | |
| DNU-SIC | ProductDescription | regular | |
| dimGeo | country | regular | |
| dimGeo | continent | regular | |
| dimGeo | sub_region | regular | |
| dimGeo | Trading Block | regular | |
| date_table | Date | regular | |
| date_table | Year | regular | |
| date_table | MonthNum | regular | |
| date_table | Month | regular | |
| date_table | Month-Year | regular | |
| date_table | Sort Key | regular | |
| MeasureTable | Selection | regular |
Pages 6
| # | Page |
|---|---|
| 0 | Landing Page |
| 1 | Import/Export/TradeBalance & Growth |
| 2 | Import/Export/TradeBalance & Growth by Category |
| 3 | Waterfall by Trading Bloc |
| 4 | Waterfall By Category |
| 5 | Decomp Tree |
Visuals 75
| Page | Visual type | Field |
|---|---|---|
| Import/Export/TradeBalance & Growth | card | MeasureTable.RecentExports |
| Import/Export/TradeBalance & Growth | card | MeasureTable.YearImport |
| Import/Export/TradeBalance & Growth | card | MeasureTable.RecentTradeBalance |
| Import/Export/TradeBalance & Growth | card | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth | slicer | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth | slicer | date_table.Year |
| Import/Export/TradeBalance & Growth | lineChart | date_table.Year |
| Import/Export/TradeBalance & Growth | lineChart | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth | lineChart | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth | lineChart | date_table.Year |
| Import/Export/TradeBalance & Growth | lineChart | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth | lineChart | MeasureTable.DynamicMeasure |
| Import/Export/TradeBalance & Growth | pivotTable | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth | pivotTable | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth | pivotTable | dimGeo.country |
| Import/Export/TradeBalance & Growth | slicer | dimSIC.Category |
| Import/Export/TradeBalance & Growth | slicer | dimSIC.Group |
| Import/Export/TradeBalance & Growth | slicer | dimSIC.Segment |
| Import/Export/TradeBalance & Growth | slicer | dimSIC.Product |
| Import/Export/TradeBalance & Growth | slicer | MeasureTable.Selection |
| Import/Export/TradeBalance & Growth | card | MeasureTable.Growth (3 Year) |
| Import/Export/TradeBalance & Growth by Category | slicer | MeasureTable.Selection |
| Import/Export/TradeBalance & Growth by Category | slicer | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth by Category | slicer | date_table.Year |
| Import/Export/TradeBalance & Growth by Category | pivotTable | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth by Category | pivotTable | dimSIC.Category |
| Import/Export/TradeBalance & Growth by Category | pivotTable | dimSIC.Group |
| Import/Export/TradeBalance & Growth by Category | pivotTable | dimSIC.Segment |
| Import/Export/TradeBalance & Growth by Category | pivotTable | dimSIC.Product |
| Import/Export/TradeBalance & Growth by Category | slicer | dimSIC.Category |
| Import/Export/TradeBalance & Growth by Category | slicer | dimSIC.Group |
| Import/Export/TradeBalance & Growth by Category | slicer | dimSIC.Segment |
| Import/Export/TradeBalance & Growth by Category | slicer | dimSIC.Product |
| Import/Export/TradeBalance & Growth by Category | lineChart | date_table.Year |
| Import/Export/TradeBalance & Growth by Category | lineChart | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth by Category | lineChart | MeasureTable.DynamicMeasure |
| Import/Export/TradeBalance & Growth by Category | lineChart | date_table.Year |
| Import/Export/TradeBalance & Growth by Category | lineChart | dimGeo.Trading Block |
| Import/Export/TradeBalance & Growth by Category | lineChart | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.YearImport |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.RecentExports |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.RecentTradeBalance |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.Growth (Year) |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.Growth (3 Year) |
| Waterfall by Trading Bloc | slicer | MeasureTable.Selection |
| Waterfall by Trading Bloc | slicer | dimGeo.Trading Block |
| Waterfall by Trading Bloc | slicer | dimSIC.Category |
| Waterfall by Trading Bloc | slicer | dimSIC.Group |
| Waterfall by Trading Bloc | slicer | dimSIC.Segment |
| Waterfall by Trading Bloc | slicer | dimSIC.Product |
| Waterfall by Trading Bloc | waterfallChart | MeasureTable.DynamicMeasure |
| Waterfall by Trading Bloc | waterfallChart | dimGeo.Trading Block |
| Waterfall by Trading Bloc | waterfallChart | date_table.Date.Variation.Date Hierarchy.Year |
| Waterfall by Trading Bloc | waterfallChart | date_table.Date.Variation.Date Hierarchy.Quarter |
| Waterfall by Trading Bloc | waterfallChart | date_table.Date.Variation.Date Hierarchy.Month |
| Waterfall by Trading Bloc | waterfallChart | date_table.Date.Variation.Date Hierarchy.Day |
| Waterfall By Category | slicer | MeasureTable.Selection |
| Waterfall By Category | slicer | dimSIC.Category |
| Waterfall By Category | slicer | dimGeo.Trading Block |
| Waterfall By Category | slicer | dimGeo.country |
| Waterfall By Category | waterfallChart | MeasureTable.DynamicMeasure |
| Waterfall By Category | waterfallChart | date_table.Date.Variation.Date Hierarchy.Year |
| Waterfall By Category | waterfallChart | date_table.Date.Variation.Date Hierarchy.Quarter |
| Waterfall By Category | waterfallChart | date_table.Date.Variation.Date Hierarchy.Month |
| Waterfall By Category | waterfallChart | date_table.Date.Variation.Date Hierarchy.Day |
| Waterfall By Category | waterfallChart | dimSIC.Category |
| Decomp Tree | slicer | MeasureTable.Selection |
| Decomp Tree | slicer | dimGeo.Trading Block |
| Decomp Tree | decompositionTreeVisual | MeasureTable.DynamicMeasure |
| Decomp Tree | decompositionTreeVisual | dimGeo.Trading Block |
| Decomp Tree | decompositionTreeVisual | dimSIC.Category |
| Decomp Tree | decompositionTreeVisual | dimSIC.Group |
| Decomp Tree | decompositionTreeVisual | dimSIC.Segment |
| Decomp Tree | decompositionTreeVisual | dimSIC.Product |
| Decomp Tree | decompositionTreeVisual | dimGeo.country |
Conditional formatting & dynamic titles 16
| Page | Visual | Field |
|---|---|---|
| Import/Export/TradeBalance & Growth | card | MeasureTable.TitleExports |
| Import/Export/TradeBalance & Growth | card | MeasureTable.TitleImports |
| Import/Export/TradeBalance & Growth | card | MeasureTable.TitleTradeBalance |
| Import/Export/TradeBalance & Growth | card | MeasureTable.TitleGrowth |
| Import/Export/TradeBalance & Growth | lineChart | MeasureTable.TitleDynamicMeasureGrowth |
| Import/Export/TradeBalance & Growth | lineChart | MeasureTable.TitleDynamicMeasure |
| Import/Export/TradeBalance & Growth | card | MeasureTable.Title3Growth |
| Import/Export/TradeBalance & Growth by Category | lineChart | MeasureTable.TitleDynamicMeasure |
| Import/Export/TradeBalance & Growth by Category | lineChart | MeasureTable.TitleDynamicMeasureGrowth |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.TitleImports |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.TitleExports |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.TitleTradeBalance |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.TitleGrowth |
| Import/Export/TradeBalance & Growth by Category | card | MeasureTable.Title3Growth |
| Waterfall by Trading Bloc | waterfallChart | MeasureTable.TitleDynamicMeasureWaterfall |
| Waterfall By Category | waterfallChart | MeasureTable.TitleDynamicMeasureWaterfallCategory |
Power Query parameters 5
| Name | Expression |
|---|---|
| Parameter1 | ... meta [IsParameterQuery=true, BinaryIdentifier=#"Sample File", Type="Binary", IsParameterQueryRequired=true] |
| Transform Sample File | let
Source = Excel.Workbook(Parameter1, null, true),
Sheet1_Sheet = Source{[Item="Sheet1",Kind="Sheet"]}[Data],
#"Promoted Headers" = Table.PromoteHeaders(Sheet1_Sheet, [PromoteAllScalars=true])
in
#"Promoted Headers" |
| Sample File | let
Source = Folder.Files("C:\Users\davidk\Desktop\writing\substack\trade\data\fact_table"),
#"Removed Columns" = Table.RemoveColumns(Source,{"Extension", "Date accessed", "Date modified", "Date created", "Attributes", "Folder Path", "Name"}),
Navigation1 = #"Removed Columns"{0}[Content]
in
Navigation1 |
| Transform File | let
Source = (Parameter1 as binary) => let
Source = Excel.Workbook(Parameter1, null, true),
Sheet1_Sheet = Source{[Item="Sheet1",Kind="Sheet"]}[Data],
#"Promoted Headers" = Table.PromoteHeaders(Sheet1_Sheet, [PromoteAllScalars=true])
in
#"Promoted Headers"
in
Source |
| FolderLocation | null meta [IsParameterQuery=true, Type="Text", IsParameterQueryRequired=true] |
Additional Info / Business Logic
This is a test, any biz logic important for report function goes here.