├── manifest.lkml ├── alight_model.model.lkml ├── LICENSE ├── channelmix_demo_oneview_paid_search_ad.view.lkml ├── v_oneview_media_and_conversion.view.lkml └── paid_media_dashboard.dashboard.lookml /manifest.lkml: -------------------------------------------------------------------------------- 1 | project_name: "alight_demo" 2 | 3 | constant: SCHEMA_NAME { 4 | value: "channelmix_demo" 5 | } 6 | -------------------------------------------------------------------------------- /alight_model.model.lkml: -------------------------------------------------------------------------------- 1 | connection: "channelmix" 2 | 3 | include: "*.view.lkml" # include all views in this project 4 | include: "*.dashboard.lookml" # include a LookML dashboard called my_dashboard 5 | 6 | # # Select the views that should be a part of this model, 7 | # # and define the joins that connect them together. 8 | # 9 | # explore: order_items { 10 | # join: orders { 11 | # relationship: many_to_one 12 | # sql_on: ${orders.id} = ${order_items.order_id} ;; 13 | # } 14 | # 15 | # join: users { 16 | # relationship: many_to_one 17 | # sql_on: ${users.id} = ${orders.user_id} ;; 18 | # } 19 | # } 20 | 21 | week_start_day: sunday 22 | 23 | named_value_format: big_int_format { 24 | value_format: "[>=1000000]0.00,,\"M\";[>=1000]0.00,\"K\";0.000" 25 | strict_value_format: yes 26 | } 27 | 28 | named_value_format: big_money_format { 29 | value_format: "[>=1000000]$0.00,,\"M\";[>=1000]$0.00,\"K\";$0.00" 30 | strict_value_format: yes 31 | } 32 | 33 | explore: v_oneview_media_and_conversion {} 34 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 Looker Data Sciences, Inc. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /channelmix_demo_oneview_paid_search_ad.view.lkml: -------------------------------------------------------------------------------- 1 | view: channelmix_demo_oneview_paid_search_ad { 2 | sql_table_name: @{SCHEMA_NAME}.channelmix_demo_oneview_paid_search_ad ;; 3 | 4 | dimension: account { 5 | type: string 6 | sql: ${TABLE}.account ;; 7 | } 8 | 9 | dimension: account_id { 10 | type: number 11 | sql: ${TABLE}.account_id ;; 12 | } 13 | 14 | dimension: ad_group { 15 | type: string 16 | sql: ${TABLE}.ad_group ;; 17 | } 18 | 19 | dimension: ad_id { 20 | type: number 21 | sql: ${TABLE}.ad_id ;; 22 | } 23 | 24 | dimension: ad_type { 25 | type: string 26 | sql: ${TABLE}.ad_type ;; 27 | } 28 | 29 | dimension: campaign { 30 | type: string 31 | sql: ${TABLE}.campaign ;; 32 | } 33 | 34 | dimension: channel { 35 | type: string 36 | sql: ${TABLE}.channel ;; 37 | } 38 | 39 | dimension: channelmix_profile { 40 | type: string 41 | sql: ${TABLE}.channelmix_profile ;; 42 | } 43 | 44 | dimension: clicks { 45 | type: number 46 | sql: ${TABLE}.clicks ;; 47 | } 48 | 49 | dimension: conversion_value { 50 | type: number 51 | sql: ${TABLE}.conversion_value ;; 52 | } 53 | 54 | dimension: conversions { 55 | type: number 56 | sql: ${TABLE}.conversions ;; 57 | } 58 | 59 | dimension: cost { 60 | type: number 61 | sql: ${TABLE}.cost ;; 62 | } 63 | 64 | dimension: data_source { 65 | type: string 66 | sql: ${TABLE}.data_source ;; 67 | } 68 | 69 | dimension: description { 70 | type: string 71 | sql: ${TABLE}.description ;; 72 | } 73 | 74 | dimension: description_line_one { 75 | type: string 76 | sql: ${TABLE}.description_line_one ;; 77 | } 78 | 79 | dimension: description_line_two { 80 | type: string 81 | sql: ${TABLE}.description_line_two ;; 82 | } 83 | 84 | dimension: device { 85 | type: string 86 | sql: ${TABLE}.device ;; 87 | } 88 | 89 | dimension: headline_one { 90 | type: string 91 | sql: ${TABLE}.headline_one ;; 92 | } 93 | 94 | dimension: headline_two { 95 | type: string 96 | sql: ${TABLE}.headline_two ;; 97 | } 98 | 99 | dimension: impressions { 100 | type: number 101 | sql: ${TABLE}.impressions ;; 102 | } 103 | 104 | dimension_group: insert { 105 | type: time 106 | timeframes: [ 107 | raw, 108 | time, 109 | date, 110 | week, 111 | month, 112 | quarter, 113 | year 114 | ] 115 | sql: ${TABLE}.insert_date ;; 116 | } 117 | 118 | dimension: platform { 119 | type: string 120 | sql: ${TABLE}.platform ;; 121 | } 122 | 123 | dimension_group: report { 124 | type: time 125 | timeframes: [ 126 | raw, 127 | date, 128 | week, 129 | month, 130 | quarter, 131 | year 132 | ] 133 | convert_tz: no 134 | datatype: date 135 | sql: ${TABLE}.report_date ;; 136 | } 137 | 138 | 139 | filter: previous_period_filter { 140 | type: date 141 | description: "Use this filter for period analysis" 142 | sql: ${previous_period} IS NOT NULL ;; 143 | } 144 | 145 | dimension: previous_period { 146 | type: string 147 | description: "The reporting period as selected by the Previous Period Filter" 148 | sql: 149 | CASE 150 | WHEN {% date_start previous_period_filter %} is not null AND {% date_end previous_period_filter %} is not null /* date ranges or in the past x days */ 151 | THEN 152 | CASE 153 | WHEN ${report_date} >= {% date_start previous_period_filter %} 154 | AND ${report_date} <= {% date_end previous_period_filter %} 155 | THEN 'This Period' 156 | WHEN ${report_date} >= DATEADD(day,-1*DATEDIFF(day,{% date_start previous_period_filter %}, {% date_end previous_period_filter %} ) + 1, DATEADD(day,-1,{% date_start previous_period_filter %} ) ) 157 | AND ${report_date} <= DATEADD(day,-1,{% date_start previous_period_filter %} ) 158 | THEN 'Previous Period' 159 | END 160 | END ;; 161 | } 162 | 163 | 164 | dimension: title { 165 | type: string 166 | sql: ${TABLE}.title ;; 167 | } 168 | 169 | dimension: url { 170 | type: string 171 | sql: ${TABLE}.url ;; 172 | } 173 | 174 | measure: count { 175 | type: count 176 | drill_fields: [] 177 | } 178 | 179 | measure: total_impressions { 180 | type: sum 181 | value_format: "0.0,\" K\"" 182 | sql: ${impressions} ;; 183 | } 184 | 185 | measure: total_clicks { 186 | type: sum 187 | value_format: "0.0,\" K\"" 188 | sql: ${clicks} ;; 189 | } 190 | 191 | measure: total_cost { 192 | label: "Cost" 193 | type: sum 194 | sql: ${cost} ;; 195 | value_format_name: usd 196 | } 197 | 198 | measure: total_conversions { 199 | label: "Conversion" 200 | type: sum 201 | sql: ${conversions};; 202 | } 203 | 204 | measure: cost_per_click { 205 | type: number 206 | sql: CASE WHEN ${total_clicks} != 0 THEN 1.0 * ${total_cost}/${total_clicks} 207 | ELSE 0 208 | END ;; 209 | value_format_name: usd 210 | } 211 | 212 | measure: click_through_rate { 213 | type: number 214 | sql: CASE WHEN ${total_impressions} != 0 THEN 1.0* ${total_clicks}/${total_impressions} 215 | ELSE 0 216 | END;; 217 | value_format_name: percent_2 218 | } 219 | 220 | measure: cost_per_conversion{ 221 | type: number 222 | sql: CASE WHEN ${total_conversions} != 0 THEN 1.0 * ${total_cost}/${total_conversions} 223 | ELSE 0 224 | END;; 225 | 226 | value_format_name: usd 227 | } 228 | measure: conversation_rate{ 229 | type: percent_of_total 230 | sql: ${total_conversions} ;; 231 | } 232 | 233 | parameter: metric1 { 234 | label: "Metric 1" 235 | type: unquoted 236 | allowed_value: { 237 | label:"Impression" 238 | value: "Impression" 239 | } 240 | 241 | allowed_value: { 242 | label: "Cost" 243 | value: "Cost" 244 | } 245 | 246 | allowed_value: { 247 | label: "Conversion Rate" 248 | value: "Conversion Rate" 249 | } 250 | 251 | allowed_value: { 252 | label: "Cost per Conversion" 253 | value: "Cost per Conversion" 254 | } 255 | 256 | allowed_value: { 257 | label: "Click through Rate" 258 | value: "Click through Rate" 259 | } 260 | 261 | allowed_value: { 262 | label: "Cost per Click" 263 | value: "Cost per Click" 264 | } 265 | 266 | allowed_value: { 267 | label: "Conversion" 268 | value: "Conversion" 269 | } 270 | 271 | allowed_value: { 272 | label: "Clicks" 273 | value: "Clicks" 274 | } 275 | } 276 | 277 | 278 | parameter: metric2 { 279 | label: "Metric 2" 280 | type: unquoted 281 | allowed_value: { 282 | label:"Impression" 283 | value: "Impression" 284 | } 285 | 286 | allowed_value: { 287 | label: "Cost" 288 | value: "Cost" 289 | } 290 | 291 | allowed_value: { 292 | label: "Conversion Rate" 293 | value: "Conversion Rate" 294 | } 295 | 296 | allowed_value: { 297 | label: "Cost per Conversion" 298 | value: "Cost per Conversion" 299 | } 300 | 301 | allowed_value: { 302 | label: "Click through Rate" 303 | value: "Click through Rate" 304 | } 305 | 306 | allowed_value: { 307 | label: "Cost per Click" 308 | value: "Cost per Click" 309 | } 310 | 311 | allowed_value: { 312 | label: "Conversion" 313 | value: "Conversion" 314 | } 315 | 316 | allowed_value: { 317 | label: "Clicks" 318 | value: "Clicks" 319 | } 320 | } 321 | 322 | measure: filtered_metric1 { 323 | type: number 324 | label_from_parameter: metric1 325 | sql: CASE WHEN '{% parameter metric1 %}' = 'Impression' THEN ${total_impressions} 326 | WHEN '{% parameter metric1 %}' = 'Cost' THEN ${total_cost} 327 | WHEN '{% parameter metric1 %}' = 'Clicks' THEN ${total_clicks} 328 | WHEN '{% parameter metric1 %}' = 'Conversion' THEN ${total_conversions} 329 | WHEN '{% parameter metric1 %}' = 'Cost per Click' THEN ${cost_per_click} 330 | WHEN '{% parameter metric1 %}' = 'Click through Rate' THEN ${click_through_rate} 331 | WHEN '{% parameter metric1 %}' = 'Cost per Conversion' THEN ${cost_per_conversion} 332 | WHEN '{% parameter metric1 %}' = 'Conversion Rate' THEN ${conversation_rate} 333 | END ;; 334 | } 335 | 336 | measure: filtered_metric2 { 337 | type: number 338 | label_from_parameter: metric2 339 | sql: CASE WHEN '{% parameter metric2 %}' = 'Impression' THEN ${total_impressions} 340 | WHEN '{% parameter metric2 %}' = 'Cost' THEN ${total_cost} 341 | WHEN '{% parameter metric2 %}' = 'Clicks' THEN ${total_clicks} 342 | WHEN '{% parameter metric2 %}' = 'Conversion' THEN ${total_conversions} 343 | WHEN '{% parameter metric2 %}' = 'Cost per Click' THEN ${cost_per_click} 344 | WHEN '{% parameter metric2 %}' = 'Click through Rate' THEN ${click_through_rate} 345 | WHEN '{% parameter metric2 %}' = 'Cost per Conversion' THEN ${cost_per_conversion} 346 | WHEN '{% parameter metric2 %}' = 'Conversion Rate' THEN ${conversation_rate} 347 | END ;; 348 | } 349 | } 350 | -------------------------------------------------------------------------------- /v_oneview_media_and_conversion.view.lkml: -------------------------------------------------------------------------------- 1 | view: v_oneview_media_and_conversion { 2 | sql_table_name: v_oneview_media_and_conversion ;; 3 | 4 | 5 | dimension: primary_key { 6 | hidden: yes 7 | primary_key: yes 8 | sql:${account} || ${campaign} || ${ad_group} || ${data_source} || ${channel} || ${platform} || ${channelmix_profile} || ${report_raw};; 9 | } 10 | dimension: account { 11 | type: string 12 | sql: ${TABLE}.account ;; 13 | } 14 | 15 | dimension: ad_group { 16 | type: string 17 | sql: ${TABLE}.ad_group ;; 18 | } 19 | 20 | dimension: campaign { 21 | type: string 22 | sql: ${TABLE}.campaign ;; 23 | } 24 | 25 | dimension: channel { 26 | type: string 27 | sql: ${TABLE}.channel ;; 28 | } 29 | 30 | dimension: channelmix_profile { 31 | type: string 32 | sql: ${TABLE}.channelmix_profile ;; 33 | } 34 | 35 | dimension: clicks { 36 | type: number 37 | sql: ${TABLE}.clicks ;; 38 | } 39 | 40 | dimension: conversion_name { 41 | type: string 42 | sql: ${TABLE}.conversion_name ;; 43 | } 44 | 45 | dimension: conversion_value { 46 | type: number 47 | sql: ${TABLE}.conversion_value ;; 48 | } 49 | 50 | dimension: conversions { 51 | type: number 52 | sql: ${TABLE}.conversions ;; 53 | } 54 | 55 | dimension: cost { 56 | type: number 57 | sql: ${TABLE}.cost ;; 58 | value_format_name: big_money_format 59 | } 60 | 61 | dimension: data_source { 62 | type: string 63 | sql: ${TABLE}.data_source ;; 64 | } 65 | 66 | dimension: impressions { 67 | type: number 68 | sql: ${TABLE}.impressions ;; 69 | } 70 | 71 | dimension_group: insert { 72 | type: time 73 | timeframes: [ 74 | raw, 75 | time, 76 | date, 77 | week, 78 | month, 79 | quarter, 80 | year 81 | ] 82 | sql: ${TABLE}.insert_date ;; 83 | } 84 | 85 | dimension: platform { 86 | type: string 87 | sql: ${TABLE}.platform ;; 88 | } 89 | 90 | dimension_group: report { 91 | type: time 92 | timeframes: [ 93 | raw, 94 | date, 95 | week, 96 | month, 97 | quarter, 98 | year 99 | ] 100 | convert_tz: no 101 | datatype: date 102 | sql: ${TABLE}.report_date ;; 103 | } 104 | 105 | 106 | filter: previous_period_filter { 107 | type: date 108 | description: "Use this filter for period analysis" 109 | sql: ${previous_period} IS NOT NULL ;; 110 | } 111 | 112 | dimension: previous_period { 113 | type: string 114 | sql: CASE WHEN ${report_date} >= {% date_start previous_period_filter %} AND ${report_date} < {% date_end previous_period_filter %} 115 | THEN 'This Period' 116 | WHEN ${report_date} >= DATEADD(day,-1*DATEDIFF(day,{% date_start previous_period_filter %}, {% date_end previous_period_filter %} ) + 1, DATEADD(day,-1,{% date_start previous_period_filter %} ) ) 117 | AND ${report_date} <= DATEADD(day,-1,{% date_start previous_period_filter %} ) 118 | THEN 'Previous Period' 119 | END;; 120 | } 121 | 122 | 123 | 124 | measure: count { 125 | type: count 126 | drill_fields: [conversion_name] 127 | } 128 | 129 | 130 | #################### 131 | # CUSTOM MEASURES # 132 | #################### 133 | 134 | measure: total_impressions { 135 | label: "Impressions" 136 | description: "Total Impressions" 137 | type: sum 138 | value_format_name: big_int_format 139 | sql: ${impressions} ;; 140 | drill_fields: [campaign, total_impressions] 141 | } 142 | 143 | measure: total_clicks { 144 | label: "Clicks" 145 | description: "Total Clicks" 146 | type: sum 147 | value_format_name: big_int_format 148 | sql: ${clicks} ;; 149 | drill_fields: [campaign, total_clicks] 150 | } 151 | 152 | measure: total_cost { 153 | label: "Cost" 154 | description: "Total Cost" 155 | type: sum 156 | sql: ${cost} ;; 157 | value_format_name: big_money_format 158 | drill_fields: [campaign, total_cost] 159 | } 160 | 161 | measure: cost_per_click { 162 | type: number 163 | sql: CASE WHEN ${total_clicks} != 0 THEN 1.0 * ${total_cost}/${total_clicks} 164 | ELSE 0 165 | END ;; 166 | value_format_name: big_money_format 167 | drill_fields: [campaign, cost_per_click] 168 | } 169 | 170 | measure: click_through_rate { 171 | type: number 172 | sql: CASE WHEN ${total_impressions} != 0 THEN 1.0* ${total_clicks}/${total_impressions} 173 | ELSE 0 174 | END;; 175 | value_format_name:percent_1 176 | drill_fields: [campaign, click_through_rate] 177 | } 178 | 179 | measure: cost_per_conversion { 180 | type: number 181 | 182 | sql: CASE WHEN (${total_conversions} != 0) THEN 1.0* (${total_cost}/${total_conversions}) 183 | ELSE 0 184 | END;; 185 | value_format_name: big_money_format 186 | drill_fields: [campaign, cost_per_conversion] 187 | 188 | } 189 | 190 | measure: total_conversions { 191 | label: "Conversion" 192 | description: "Total Conversion" 193 | type: sum 194 | sql: ${conversions};; 195 | value_format_name: big_int_format 196 | drill_fields: [campaign, total_conversions] 197 | 198 | } 199 | 200 | measure: conversion_rate { 201 | type: number 202 | sql: ${total_conversions}/NULLIF(${total_clicks},0) ;; 203 | value_format_name: percent_1 204 | drill_fields: [campaign, total_conversions] 205 | } 206 | 207 | ##################### 208 | # DYNAMIC FILTERING # 209 | ##################### 210 | 211 | parameter: metric1 { 212 | label: "Metric 1" 213 | type: unquoted 214 | allowed_value: { 215 | label:"Impression" 216 | value: "Impression" 217 | } 218 | 219 | allowed_value: { 220 | label: "Cost" 221 | value: "Cost" 222 | } 223 | 224 | allowed_value: { 225 | label: "Click through Rate" 226 | value: "Click_through_Rate" 227 | } 228 | 229 | allowed_value: { 230 | label: "Cost per Click" 231 | value: "Cost_per_Click" 232 | } 233 | 234 | allowed_value: { 235 | label: "Conversion" 236 | value: "Conversion" 237 | } 238 | 239 | allowed_value: { 240 | label: "Clicks" 241 | value: "Clicks" 242 | } 243 | } 244 | 245 | 246 | parameter: metric2 { 247 | label: "Metric 2" 248 | type: unquoted 249 | allowed_value: { 250 | label:"Impression" 251 | value: "Impression" 252 | } 253 | 254 | allowed_value: { 255 | label: "Cost" 256 | value: "Cost" 257 | } 258 | 259 | allowed_value: { 260 | label: "Click through Rate" 261 | value: "Click_through_Rate" 262 | } 263 | 264 | allowed_value: { 265 | label: "Cost per Click" 266 | value: "Cost_per_Click" 267 | } 268 | 269 | allowed_value: { 270 | label: "Conversion" 271 | value: "Conversion" 272 | } 273 | 274 | allowed_value: { 275 | label: "Clicks" 276 | value: "Clicks" 277 | } 278 | } 279 | 280 | # filter: newmetric { 281 | # 282 | # type: string 283 | # suggestions: ["Clicks","Conversion","Cost_Per_Click"] 284 | # } 285 | 286 | measure: filtered_metric1 { 287 | type: number 288 | label_from_parameter: metric1 289 | sql: CASE WHEN '{% parameter metric1 %}' = 'Impression' THEN ${total_impressions} 290 | WHEN '{% parameter metric1 %}' = 'Cost' THEN ${total_cost} 291 | WHEN '{% parameter metric1 %}' = 'Clicks' THEN ${total_clicks} 292 | WHEN '{% parameter metric1 %}' = 'Cost_per_Click' THEN ${cost_per_click} 293 | WHEN '{% parameter metric1 %}' = 'Click_through_Rate' THEN ${click_through_rate} 294 | WHEN '{% parameter metric1 %}' = 'Conversion' THEN ${total_conversions} 295 | END ;; 296 | value_format: "0.00" 297 | html: {{rendered_value}} ;; 298 | } 299 | 300 | measure: filtered_metric2 { 301 | type: number 302 | label_from_parameter: metric2 303 | sql: CASE WHEN '{% parameter metric2 %}' = 'Impression' THEN ${total_impressions} 304 | WHEN '{% parameter metric2 %}' = 'Cost' THEN ${total_cost} 305 | WHEN '{% parameter metric2 %}' = 'Clicks' THEN ${total_clicks} 306 | WHEN '{% parameter metric2 %}' = 'Cost_per_Click' THEN ${cost_per_click} 307 | WHEN '{% parameter metric2 %}' = 'Click_through_Rate' THEN ${click_through_rate} 308 | WHEN '{% parameter metric2 %}' = 'Conversion' THEN ${total_conversions} 309 | 310 | END ;; 311 | } 312 | 313 | 314 | 315 | 316 | parameter: timeframe_picker { 317 | label: "Date Granularity" 318 | type: string 319 | allowed_value: { value: "Date" } 320 | allowed_value: { value: "Week" } 321 | allowed_value: { value: "Month" } 322 | allowed_value: { value: "Quarter" } 323 | default_value: "Date" 324 | } 325 | 326 | 327 | dimension: dynamic_timeframe { 328 | type: string 329 | sql: 330 | CASE 331 | WHEN {% parameter timeframe_picker %} = 'Date' THEN (TO_CHAR(DATE_TRUNC('day', v_oneview_media_and_conversion.report_date ), 'YYYY-MM-DD')) 332 | WHEN {% parameter timeframe_picker %} = 'Week' THEN ${report_week} 333 | WHEN {% parameter timeframe_picker %} = 'Month' THEN ${report_month} 334 | WHEN {% parameter timeframe_picker %} = 'Quarter' THEN ${report_quarter} 335 | 336 | END ;; 337 | } 338 | 339 | 340 | parameter: performance_metric_by { 341 | label: "Performance Metric" 342 | type: string 343 | allowed_value: { value: "Source" } 344 | allowed_value: { value: "Channel" } 345 | allowed_value: { value: "Campaign" } 346 | default_value: "Source" 347 | } 348 | 349 | 350 | dimension: dynamic_performance { 351 | type: string 352 | sql: 353 | CASE 354 | WHEN {% parameter performance_metric_by %} = 'Source' THEN ${data_source} 355 | WHEN {% parameter performance_metric_by %} = 'Channel' THEN ${channel} 356 | WHEN {% parameter performance_metric_by %} = 'Campaign' THEN ${campaign} 357 | END ;; 358 | } 359 | } 360 | -------------------------------------------------------------------------------- /paid_media_dashboard.dashboard.lookml: -------------------------------------------------------------------------------- 1 | - dashboard: paid_media_dashboard 2 | title: Paid Media Dashboard 3 | layout: newspaper 4 | elements: 5 | - name: Paid Media Dashboard 6 | type: text 7 | title_text: Paid Media Dashboard 8 | row: 0 9 | col: 6 10 | width: 12 11 | height: 3 12 | - title: Impressions 13 | name: Impressions 14 | model: alight_model 15 | explore: v_oneview_media_and_conversion 16 | type: single_value 17 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.total_impressions] 18 | filters: 19 | v_oneview_media_and_conversion.previous_period: "-NULL" 20 | sorts: [v_oneview_media_and_conversion.previous_period desc] 21 | limit: 100 22 | column_limit: 50 23 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.total_impressions}/offset(${v_oneview_media_and_conversion.total_impressions},1))\ 24 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 25 | _type_hint: number}] 26 | custom_color_enabled: true 27 | custom_color: '' 28 | show_single_value_title: true 29 | show_comparison: true 30 | comparison_type: change 31 | comparison_reverse_colors: false 32 | show_comparison_label: false 33 | series_types: {} 34 | hidden_fields: [] 35 | y_axes: [] 36 | listen: 37 | Campaign: v_oneview_media_and_conversion.campaign 38 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 39 | Date: v_oneview_media_and_conversion.previous_period_filter 40 | row: 3 41 | col: 0 42 | width: 5 43 | height: 4 44 | - title: Cost 45 | name: Cost 46 | model: alight_model 47 | explore: v_oneview_media_and_conversion 48 | type: single_value 49 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.total_cost] 50 | filters: 51 | v_oneview_media_and_conversion.previous_period: "-NULL" 52 | sorts: [v_oneview_media_and_conversion.previous_period desc] 53 | limit: 100 54 | column_limit: 50 55 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.total_cost}/offset(${v_oneview_media_and_conversion.total_cost},1))\ 56 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 57 | _type_hint: number}] 58 | custom_color_enabled: true 59 | custom_color: '' 60 | show_single_value_title: true 61 | show_comparison: true 62 | comparison_type: change 63 | comparison_reverse_colors: true 64 | show_comparison_label: false 65 | enable_conditional_formatting: false 66 | conditional_formatting_include_totals: false 67 | conditional_formatting_include_nulls: false 68 | series_types: {} 69 | hidden_fields: [] 70 | y_axes: [] 71 | listen: 72 | Campaign: v_oneview_media_and_conversion.campaign 73 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 74 | Date: v_oneview_media_and_conversion.previous_period_filter 75 | row: 3 76 | col: 5 77 | width: 5 78 | height: 4 79 | - title: Clicks 80 | name: Clicks 81 | model: alight_model 82 | explore: v_oneview_media_and_conversion 83 | type: single_value 84 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.total_clicks] 85 | filters: 86 | v_oneview_media_and_conversion.previous_period: "-NULL" 87 | sorts: [v_oneview_media_and_conversion.previous_period desc] 88 | limit: 100 89 | column_limit: 50 90 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.total_clicks}/offset(${v_oneview_media_and_conversion.total_clicks},1))\ 91 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 92 | _type_hint: number}] 93 | custom_color_enabled: true 94 | custom_color: '' 95 | show_single_value_title: true 96 | show_comparison: true 97 | comparison_type: change 98 | comparison_reverse_colors: false 99 | show_comparison_label: false 100 | series_types: {} 101 | hidden_fields: [] 102 | y_axes: [] 103 | listen: 104 | Campaign: v_oneview_media_and_conversion.campaign 105 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 106 | Date: v_oneview_media_and_conversion.previous_period_filter 107 | row: 7 108 | col: 0 109 | width: 5 110 | height: 4 111 | - title: Cost per Click 112 | name: Cost per Click 113 | model: alight_model 114 | explore: v_oneview_media_and_conversion 115 | type: single_value 116 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.cost_per_click] 117 | filters: 118 | v_oneview_media_and_conversion.previous_period: "-NULL" 119 | sorts: [v_oneview_media_and_conversion.previous_period desc] 120 | limit: 100 121 | column_limit: 50 122 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.cost_per_click}/offset(${v_oneview_media_and_conversion.cost_per_click},1))\ 123 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 124 | _type_hint: number}] 125 | custom_color_enabled: true 126 | custom_color: '' 127 | show_single_value_title: true 128 | show_comparison: true 129 | comparison_type: change 130 | comparison_reverse_colors: true 131 | show_comparison_label: false 132 | enable_conditional_formatting: false 133 | conditional_formatting_include_totals: false 134 | conditional_formatting_include_nulls: false 135 | series_types: {} 136 | hidden_fields: [] 137 | y_axes: [] 138 | listen: 139 | Campaign: v_oneview_media_and_conversion.campaign 140 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 141 | Date: v_oneview_media_and_conversion.previous_period_filter 142 | row: 7 143 | col: 5 144 | width: 5 145 | height: 4 146 | - title: Conversions 147 | name: Conversions 148 | model: alight_model 149 | explore: v_oneview_media_and_conversion 150 | type: single_value 151 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.total_conversions] 152 | filters: 153 | v_oneview_media_and_conversion.previous_period: "-NULL" 154 | sorts: [v_oneview_media_and_conversion.previous_period desc] 155 | limit: 100 156 | column_limit: 50 157 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.total_conversions}/offset(${v_oneview_media_and_conversion.total_conversions},1))\ 158 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 159 | _type_hint: number}] 160 | custom_color_enabled: true 161 | custom_color: '' 162 | show_single_value_title: true 163 | show_comparison: true 164 | comparison_type: change 165 | comparison_reverse_colors: false 166 | show_comparison_label: false 167 | series_types: {} 168 | hidden_fields: [] 169 | y_axes: [] 170 | listen: 171 | Campaign: v_oneview_media_and_conversion.campaign 172 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 173 | Date: v_oneview_media_and_conversion.previous_period_filter 174 | row: 11 175 | col: 0 176 | width: 5 177 | height: 4 178 | - title: Cost per Conversion 179 | name: Cost per Conversion 180 | model: alight_model 181 | explore: v_oneview_media_and_conversion 182 | type: single_value 183 | fields: [v_oneview_media_and_conversion.previous_period, v_oneview_media_and_conversion.cost_per_conversion] 184 | filters: 185 | v_oneview_media_and_conversion.previous_period: "-NULL" 186 | sorts: [v_oneview_media_and_conversion.previous_period desc] 187 | limit: 100 188 | column_limit: 50 189 | dynamic_fields: [{table_calculation: percent_change, label: Percent Change, expression: "(${v_oneview_media_and_conversion.cost_per_conversion}/offset(${v_oneview_media_and_conversion.cost_per_conversion},1))\ 190 | \ - 1", value_format: !!null '', value_format_name: percent_0, _kind_hint: measure, 191 | _type_hint: number}] 192 | custom_color_enabled: true 193 | custom_color: '' 194 | show_single_value_title: true 195 | show_comparison: true 196 | comparison_type: change 197 | comparison_reverse_colors: true 198 | show_comparison_label: false 199 | enable_conditional_formatting: false 200 | conditional_formatting_include_totals: false 201 | conditional_formatting_include_nulls: false 202 | series_types: {} 203 | hidden_fields: [] 204 | y_axes: [] 205 | listen: 206 | Campaign: v_oneview_media_and_conversion.campaign 207 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 208 | Date: v_oneview_media_and_conversion.previous_period_filter 209 | row: 11 210 | col: 5 211 | width: 5 212 | height: 4 213 | - name: 214 | type: text 215 | title_text: 216 | row: 0 217 | col: 0 218 | width: 6 219 | height: 3 220 | - title: Metric Comparison Trend 221 | name: Metric Comparison Trend 222 | model: alight_model 223 | explore: v_oneview_media_and_conversion 224 | type: looker_line 225 | fields: [v_oneview_media_and_conversion.filtered_metric1, v_oneview_media_and_conversion.filtered_metric2, 226 | v_oneview_media_and_conversion.dynamic_timeframe] 227 | sorts: [v_oneview_media_and_conversion.dynamic_timeframe] 228 | limit: 500 229 | query_timezone: America/Los_Angeles 230 | x_axis_gridlines: false 231 | y_axis_gridlines: true 232 | show_view_names: false 233 | y_axes: [{label: '', orientation: left, series: [{axisId: v_oneview_media_and_conversion.filtered_metric1, 234 | id: v_oneview_media_and_conversion.filtered_metric1, name: Impression}], 235 | showLabels: true, showValues: true, unpinAxis: false, tickDensity: default, 236 | type: linear}, {label: !!null '', orientation: right, series: [{axisId: v_oneview_media_and_conversion.filtered_metric2, 237 | id: v_oneview_media_and_conversion.filtered_metric2, name: Cost}], showLabels: true, 238 | showValues: true, unpinAxis: false, tickDensity: default, type: linear}] 239 | show_y_axis_labels: true 240 | show_y_axis_ticks: true 241 | y_axis_tick_density: default 242 | y_axis_tick_density_custom: 5 243 | show_x_axis_label: true 244 | show_x_axis_ticks: true 245 | y_axis_scale_mode: linear 246 | x_axis_reversed: false 247 | y_axis_reversed: false 248 | plot_size_by_field: false 249 | trellis: '' 250 | stacking: '' 251 | limit_displayed_rows: false 252 | legend_position: center 253 | series_types: {} 254 | point_style: none 255 | show_value_labels: false 256 | label_density: 25 257 | x_axis_scale: auto 258 | y_axis_combined: true 259 | show_null_points: true 260 | interpolation: linear 261 | hidden_fields: [] 262 | listen: 263 | Campaign: v_oneview_media_and_conversion.campaign 264 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 265 | Date: v_oneview_media_and_conversion.report_date 266 | Metric 1: v_oneview_media_and_conversion.metric1 267 | Metric 2: v_oneview_media_and_conversion.metric2 268 | TimeFrame Reporting: v_oneview_media_and_conversion.timeframe_picker 269 | row: 3 270 | col: 10 271 | width: 14 272 | height: 6 273 | - title: Performance Metrics Table 274 | name: Performance Metrics Table 275 | model: alight_model 276 | explore: v_oneview_media_and_conversion 277 | type: looker_grid 278 | fields: [v_oneview_media_and_conversion.total_impressions, v_oneview_media_and_conversion.total_cost, 279 | v_oneview_media_and_conversion.total_clicks, v_oneview_media_and_conversion.click_through_rate, 280 | v_oneview_media_and_conversion.cost_per_click, v_oneview_media_and_conversion.total_conversions, 281 | v_oneview_media_and_conversion.conversion_rate, v_oneview_media_and_conversion.cost_per_conversion, 282 | v_oneview_media_and_conversion.dynamic_performance] 283 | limit: 500 284 | total: true 285 | show_view_names: false 286 | show_row_numbers: true 287 | transpose: false 288 | truncate_text: true 289 | hide_totals: false 290 | hide_row_totals: false 291 | size_to_fit: true 292 | series_cell_visualizations: 293 | v_oneview_media.total_impressions: 294 | is_active: false 295 | table_theme: white 296 | limit_displayed_rows: false 297 | enable_conditional_formatting: false 298 | header_text_alignment: left 299 | header_font_size: '12' 300 | rows_font_size: '12' 301 | conditional_formatting_include_totals: false 302 | conditional_formatting_include_nulls: false 303 | series_types: {} 304 | hidden_fields: [] 305 | y_axes: [] 306 | listen: 307 | Campaign: v_oneview_media_and_conversion.campaign 308 | Channelmix Profile: v_oneview_media_and_conversion.channelmix_profile 309 | Date: v_oneview_media_and_conversion.report_date 310 | Performance Metric: v_oneview_media_and_conversion.performance_metric_by 311 | row: 9 312 | col: 10 313 | width: 14 314 | height: 6 315 | filters: 316 | - name: Campaign 317 | title: Campaign 318 | type: field_filter 319 | default_value: '' 320 | allow_multiple_values: true 321 | required: false 322 | model: alight_model 323 | explore: v_oneview_media_and_conversion 324 | listens_to_filters: [] 325 | field: v_oneview_media_and_conversion.campaign 326 | - name: Channelmix Profile 327 | title: Channelmix Profile 328 | type: field_filter 329 | default_value: '' 330 | allow_multiple_values: true 331 | required: false 332 | model: alight_model 333 | explore: v_oneview_media_and_conversion 334 | listens_to_filters: [] 335 | field: v_oneview_media_and_conversion.channelmix_profile 336 | - name: Date 337 | title: Date 338 | type: date_filter 339 | default_value: 2018/12/01 to 2019/01/01 340 | allow_multiple_values: true 341 | required: false 342 | - name: Metric 1 343 | title: Metric 1 344 | type: field_filter 345 | default_value: Impression 346 | allow_multiple_values: true 347 | required: false 348 | model: alight_model 349 | explore: v_oneview_media_and_conversion 350 | listens_to_filters: [] 351 | field: v_oneview_media_and_conversion.metric1 352 | - name: Metric 2 353 | title: Metric 2 354 | type: field_filter 355 | default_value: Cost 356 | allow_multiple_values: true 357 | required: false 358 | model: alight_model 359 | explore: v_oneview_media_and_conversion 360 | listens_to_filters: [] 361 | field: v_oneview_media_and_conversion.metric2 362 | - name: TimeFrame Reporting 363 | title: TimeFrame Reporting 364 | type: field_filter 365 | default_value: Date 366 | allow_multiple_values: true 367 | required: false 368 | model: alight_model 369 | explore: v_oneview_media_and_conversion 370 | listens_to_filters: [] 371 | field: v_oneview_media_and_conversion.timeframe_picker 372 | - name: Performance Metric 373 | title: Performance Metric 374 | type: field_filter 375 | default_value: Source 376 | allow_multiple_values: true 377 | required: false 378 | model: alight_model 379 | explore: v_oneview_media_and_conversion 380 | listens_to_filters: [] 381 | field: v_oneview_media_and_conversion.performance_metric_by 382 | --------------------------------------------------------------------------------