-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
1707 lines (1073 loc) · 37.9 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html>
<head>
<title>Excel for Data Analysis II - NYC Parks</title>
<meta charset="utf-8">
<link rel="stylesheet" href="slide.css"/>
</head>
<body>
<textarea id="source">
layout:true
<div class="header" style="display:block; text-align: left; color:gray; font-size:1em; position: fixed; top: 0px; left: 0px; height: 30px;vertical-align:middle;margin:7px 0 0 0;width:100%;background: #fcfcfc;
background: -moz-linear-gradient(top, #fcfcfc 0%, #d1d1d1 100%);
background: -webkit-linear-gradient(top, #fcfcfc 0%,#d1d1d1 100%);
background: linear-gradient(to bottom, #fcfcfc 0%,#d1d1d1 100%);
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#fcfcfc', endColorstr='#d1d1d1',GradientType=0 );">
<img src="images/datapolitan_transparent_small.png" style="position: fixed;top: 2px; left: 5px; width: 14%;">
<p style="display:block;text-align:left;color:gray;font-size:1em; position: fixed; top: 0px; left: 155px; height: 30px;vertical-align:middle;margin:7px 0 0 0; ">Excel for Data Analysis II - NYC Parks and Recreation</p>
</div>
<div class="footer" style="display:block;color:gray;position:fixed;bottom: 0px;left:0px;height:30px;vertical-align:middle;margin:0 0 0 0;width:100%;background: #fcfcfc;background: -moz-linear-gradient(top, #fcfcfc 0%, #d1d1d1 100%);background: -webkit-linear-gradient(top, #fcfcfc 0%,#d1d1d1 100%);background: linear-gradient(to bottom, #fcfcfc 0%,#d1d1d1 100%);sfilter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#fcfcfc', endColorstr='#d1d1d1',GradientType=0 );">
<p class="footer">
<span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">Excel for Data Analysis II</span> by <a xmlns:cc="http://creativecommons.org/ns#" href="http://www.datapolitan.com" target="_blank" property="cc:attributionName" rel="cc:attributionURL">Richard Dunks</a>, Elizabeth DiLuzio, and Mark Yarish is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/">Creative Commons Attribution-ShareAlike 4.0 International License</a>.<a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative-Commons-License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/80x15.png" /></a>
</p>
</div>
<!-- <p class="footer">
<span xmlns:dct="http://purl.org/dc/terms/" property="dct:title">Data Analytics for NYC Parks</span> by <a xmlns:cc="http://creativecommons.org/ns#" href="http://www.datapolitan.com" property="cc:attributionName" rel="cc:attributionURL">Richard Dunks</a> and <a xmlns:cc="http://creativecommons.org/ns#" href="http://www.tinypanther.pizza" property="cc:attributionName" rel="cc:attributionURL">Julia Marden</a> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/">Creative Commons Attribution-ShareAlike 4.0 International License</a>.<a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative-Commons-License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/80x15.png" /></a>
</p> -->
--
class:center, middle
![img-center-50](images/datapolitan.png)
# Excel for Data Analysis II<br>City of New York Parks and Recreation
- - -
## Instructors: Richard Dunks and Elizabeth DiLuzio
## Teaching Assistant: Mark Yarish
### Follow along at: http://bit.ly/excel-analysis-ii
#### See the code at: http://bit.ly/excel-analysis-ii-code
---
class:center,middle
<!-- start of A block -->
# Welcome
???
+ Facilitators and TA introduce themselves, establishing mastery but also creating openings for vulnerability and awareness
---
# [Zoom Drill](https://www.loom.com/share/c00ec8e6feb74226a0283175cba23e64)
???
+ Facilitators will cover the following skills: muting themselves, stopping their video, typing in chat box, raising their hand, sharing their screen
--
+ Mute and Unmute your microphone
--
+ Start and Stop your video
--
+ Post a message in the Chat window with your name, computer operating system (Windows or MacOS), and Excel version
--
+ Click the Participants window and Raise your hand
--
+ Share and Unshare your screen
---
# A Few Ground Rules
???
+ Facilitators establish the intention we have for the culture of the classroom
--
+ Step up, step back
--
+ One mic
--
+ Be curious and ask questions
--
+ Assume noble regard and positive intent
--
+ Be present (phone, email, social media, etc.)
---
# Introduce Yourself to Your Neighbor
+ Who are you?
+ Where do you work?
+ What has been the proudest moment in your job?
+ If you were an Excel function, which one would you be?
???
+ An opportunity for participants to get to know each other and settle into the class
+ We bring them into a positive space related to their work
+ Facilitator reminds them the data isn't the end but the means to achieve the actions that make us feel good about our jobs
---
# What to Expect Today
???
+ An opportunity to set expectations about the topics covered today
--
+ Practice with group ideation and process mapping
--
+ Practice with more advanced Excel skills
--
+ Exploration of key data visualization concepts
--
+ Useful practice with NYC Parks data
---
exclude: true
# Housekeeping
+ We’ll have one 15 minute break in the morning
+ We’ll have an hour for lunch
+ We’ll have a 15 minute break in the afternoon
+ Class will start promptly after breaks
+ Feel free to step away from your computer if you need during class
+ Please take any phone conversations into the hall to not disrupt the class
???
+ Facilitator sets expectations with the students
+ Establishes the "contract" for the class
---
# Housekeeping
???
+ Facilitator sets expectations with the students
+ Establishes the "contract" for the class
--
+ We’ll have one 15 minute break in the morning
--
+ We’ll have an hour for lunch
--
+ We’ll have a 15 minute break in the afternoon
--
+ Instruction will start promptly after breaks
--
+ Feel free to step away from your computer if you need during instruction
--
+ Please remember to keep yourself muted and type any questions you have into the chat box
---
exclude:true
name:datp-review
class:center,middle
# A Review of <br>[Introduction to Data Analytics](http://training.datapolitan.com/parks-intro-analytics/#1) and <br>[Excel for Data Analysis I](http://training.datapolitan.com/parks-excel-analysis-i/#1)
---
name:objectives
class:center,middle
# What do you hope to learn today?
## Solo jot
---
# [PollEverywhere](https://polleverywhere.com)
+ Online polling tool
--
+ Can respond via text or online
--
+ VIA TEXT: Open a new text message to the number 22333. In the text message body, type LUCKYHAT776 and hit send.
![img-center-40](images/polleverywheretext.png)
--
<br>
+ VIA WEB: Visit [PollEv.com/luckyhat776](https://pollev.com/luckyhat776)
---
name:objectives
# What do you hope to learn today?
## Type one thing you'd like to learn at a time into the text box and click "Submit"
![img-right-40](images/polleverywhereupvote1.png)
---
# What do you hope to learn today?
## Read through other people's entries and upvote or downvote
![img-right-40](images/polleverywhereupvote2.png)
---
exclude: true
# What Do You Remember Learning In These Classes?
+ 3 minutes to brainstorm on your own
+ 3 minutes to share in your groups
+ 7 minutes to collaborate as a class
???
+ Walk through the steps, answer questions, then take 7 minutes to gather answers and map them out in a concept map with "Data-Driven Culture" in the center
+ Note in the class shareout where students are feeling comfortable vs uncomfortable, what they remember vs forget. Let this guide the upcoming Excel review.
---
# Every Good Analysis Begins with a Question
![img-center-90](images/valuechain.png)
---
# Which Boro Has the Most Inspections?
???
+ Have class vote and share their hypotheses
+ How do we get there?
--
![img-center-100](images/inspectionsbyboro_rev.png)
---
class:center,middle
# Let's Get Started
## Download [Parks Inspection Program Data](data/PIPData.xlsx)
---
# Parks Inspection Program (PIP)
???
+ Ask what is known about the dataset.
+ Download the dataset by clicking on the link. Do a quick datawalk.
--
+ Random, detailed inspections of NYC Parks facilities
--
+ Inspectors conduct approximately 6,000 inspections/year
--
+ Each site receives rating of "Acceptable" or "Unacceptable" based on condition of park features
--
## For more information, [click here](https://www.nycgovparks.org/park-features/parks-inspection-program)
---
name:short-boro
# Create "Short Boro" Column
--
+ We will use the <a href="https://support.office.com/en-us/article/LEFT-LEFTB-functions-9203d2d2-7960-479b-84c6-1ea52b99640c" target="_blank">LEFT function</a>
--
+ Useful for extracting a portion of a cell's contents
--
+ We'll use the <a href="https://www.howtogeek.com/school/microsoft-excel-formulas-and-functions/lesson2/" target="_blank">Function Wizard</a> to guide us through
--
<br>
<br>
![img-center-100](images/formulabuilder.png)
---
# Create "Short Boro" Column
![img-right-50](images/leftfunction.png)
## Syntax
### =LEFT(<span style="color:red">text</span>, <span style="color:orange">[num_chars]</span>)
--
## What it Says
### =LEFT ( <span style="color:red">"use this value"</span> , <span style="color:orange">"extract the first XX characters"</span> )
---
# Create "Short Boro" Column
![img-center-100](images/leftfunctionaction.png)
---
# Create a Pivot Table
![img-center-100](images/pt1.png)
--
![img-center-60](images/pt2.png)
---
# Create a Pivot Table
![img-left-35](images/pt3_rev.png)
--
![img-right-40](images/pt4_box.png)
--
![img-right-55](images/pt5_box.png)
---
# Create a Chart
+ Retype the `Row Labels` to give the chart good labels
![img-center-100](images/pt6_rev.png)
---
# 5 Analytic Tasks
???
+ Ground participants in the 5 analytic tasks with a quick review showing them the task in the context of the PIP data
+ Focus on the things we did in Excel I in the latter three categories.
+ Use the concept map as a guide to scaffold on existing knowledge
--
+ Sort
???
+ Note the dates won't sort in order -> some 2004-2012 are in as 1904-1912
+ Good thing to point out and discuss dates and times in Excel
--
+ Filter
--
+ Aggregate
--
+ Transform
--
+ Visualize
---
exclude: true
# What questions do you have about the data?
???
+ Walk participants through the stages
+ When it comes time to decide on the question, remind them that, to make the day more interesting, they should chose a more complex problem with multiple steps
+ 3 minutes to brainstorm questions you have on your own
+ 5 minutes to share and consolidate your questions with your group
+ 5 minutes to decide on who will answer which questions
---
# What questions do you have about the data?
+ 3 minutes to brainstorm questions you have on your own
--
+ [Share out](pollEv.com/luckyhat776)
--
+ Sign up for your question for the day (no more than 4 people per question)
---
exclude:true
# What are the steps you will need to take to answer your questions?
+ 3 minutes to brainstorm steps on your own
+ 3 minutes to share and consolidate the steps with your group
+ 3 minutes to arrange the steps you will take to do the analysis
???
+ Walk participants through the stages
+ When it comes time to decide on the question, remind them that, to make the day more interesting, they should chose a more complex problem with multiple steps
---
class:center,middle
<!-- end of A block -->
# WRAP-UP
![img-center-100](images/imp_guide.png)
???
+ Facilitator reflects on material with students to get a view on what we've covered
+ Facilitator discussed the Implementation Guide and invites them to use it in the course of the class
---
class:center,middle
# 15 MIN BREAK
---
# Documenting Your Work
???
+ Facilitator discusses the importance of documentation and why we do it as a refresher from previous classes
+ Have participants name their styles for documenting and what they remember from last class before going through the list
--
+ Important for communicating what you have done with others
--
+ Create a new tab with a running list
--
+ Add comments to a blank column at the end of your dataset
--
+ Other ways?
---
# Let's get back into the data
--
## Remember
--
![img-right-10](images/chat.png)
+ If you have a question, type it in the chat window
--
+ If you need help, raise your hand
![img-center-30](images/part_rh.png)
---
# Functions in Excel
???
+ Facilitator reviews functions by soliciting examples from participants on the use of functions in their work
--
+ Allow you to do calculations in Excel
--
+ Also allow you to manipulate text
--
+ <a href="https://support.office.com/en-ie/article/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb" target="_blank">And a whole lot more...</a>
---
class:center,middle
# What if we wanted to have the full boro name in our data?
---
class:center,middle
# First of all...
---
name:conditional
# Conditional Formulas
--
+ Useful when the output of a formula needs to change depending on the input
--
+ Creates more flexibility
--
+ Often used with some kind of logical test (usually an `IF`)
---
# Morning vs Afternoon Inspections
+ Create a new column "Time of Day"
--
![img-center-90](images/tod1.png)
--
<br>
![img-center-90](images/tod2.png)
???
+ Note there are 4 rows with errors because times aren't formatted properly (text instead of serial)
--
## What are we telling Excel to do?
---
# Morning vs Afternoon Inspections
![img-center-70](images/tod3.PNG)
---
# Logical Functions
--
+ `IF` is an example of a logical function
--
+ Syntax<br>=IF(<span style="color:red">logical_test</span>, <span style="color:orange">[value_if_true]</span>, <span style="color:green">[value_if_false]</span>)
???
+ Play the formula out. What happens when it's not a B?
+ What solutions can the group think of?
--
+ What it Says<br>=IF ( <span style="color:red">"test this statement I'm telling you"</span> , <span style="color:orange">"if it's true, return this value"</span>, <span style="color:green">"if it's false, return this other value"</span> )
--
+ Logical functions return the value of TRUE or FALSE depending on the test you construct
---
name:cf-examples
# Examples of Other Logical Functions
???
+ Facilitator describes examples of logical functions and polls for usage among participants
--
+ [AND](https://support.office.com/en-ie/article/and-function-5f19b2e8-e1df-4408-897a-ce285a19e9d9): All conditions must be TRUE or this will return FALSE
--
+ [OR](https://support.office.com/en-ie/article/or-function-7d17ad14-8700-4281-b308-00b131e22af0): If at least one condition is TRUE, this will return TRUE
--
+ [NOT](https://support.office.com/en-ie/article/not-function-9cfc6011-a054-40c7-a140-cd4ba2d87d77): Makes TRUE into FALSE and FALSE into TRUE
--
+ [COUNTIF](https://support.office.com/en-us/article/COUNTIF-function-E0DE10C6-F885-4E71-ABB4-1F464816DF34): Count all the numbers in a specified range if they meet a specified criteria
--
+ [SUMIF](https://support.office.com/en-us/article/SUMIF-function-169B8C99-C05C-4483-A712-1697A653039B): Sum all the numbers in a specified range if they meet a specified criteria
---
exclude:true
name:logic-fn
# Logical Functions
+ IF is an example of a logical function
+ Logical functions perform a test, returning one value for TRUE and another if FALSE
+ Pro: they help you to create new data by drawing simple conclusions
+ Con: They are binary, so they are limited in power
---
# Nesting Functions
--
+ Notice we didn't rely on just one function to accomplish this task
--
![img-center-100](images/nest1.png)
--
+ In this case, we used the output from the `HOUR` function as part of the input to our `IF` function
--
+ This is called "nesting" and helps us create more complex formulas
---
exclude:true
# Create "Full Boro" Column
+ We will use the IF function
![img-right-45](images/iffunction.png)
???
+ Facilitator polls class for understanding and usage of the `IF` function before proceeding
---
name:full-boro
class:middle
# Back to our question:
# What if we wanted to have the full boro name in our data?
---
# Create "Full Boro" Column
![img-center-100](images/iffunctionaction.png)
---
# Nested IF Statement Example
## Syntax
### =IF(<span style="color:red">logical_test</span>,<span style="color:orange">[value_if_true]</span>,<span style="color:green">IF(</span><span style="color:red">logical_test</span>,<span style="color:orange">[value_if_true]</span>,<span style="color:green">IF(</span><span style="color:red">logical_test</span>,<span style="color:orange">[value_if_true]</span>,<span style="color:green">[value_if_false]</span>)
--
## What it Says
### =IF ( <span style="color:red">"test this statement I'm telling you"</span> , <span style="color:orange">"if it's true, return this value"</span>, <span style="color:green">"if it's false..."</span> <span style="color:red">"test this statement I'm telling you"</span> , <span style="color:orange">"if it's true, return this value"</span>, <span style="color:green">"if it's false..."</span> <span style="color:red">"test this statement I'm telling you"</span> , <span style="color:orange">"if it's true, return this value"</span>, <span style="color:green">"if it's false, return this other value"</span> )
---
# Create "Full Boro" Column
![img-center-100](images/nestedifs.png)
???
+ The formula is:
```
=IF(B2="B","Brooklyn",IF(B2="M","Manhattan",IF(B2="Q","Queens",IF(B2="X","Bronx",IF(B2="R","Staten Island","Other")))))
```
--
### =IF ( <span style="color:red">"test to see if B4 is equal to "B""</span> , <span style="color:orange">"if it's true, return Brooklyn"</span>, <span style="color:green">"if it's false..."</span> <span style="color:red">"test to see if B4 is equal to "Q""</span> , <span style="color:orange">"if it's true, return Queens"</span>, <span style="color:green">"if it's false..."</span> <span style="color:red">"test to see if B4 is equal to "M""</span> , <span style="color:orange">"if it's true, return Manhattan"</span>, <span style="color:green">"if it's false..."</span> <span style="color:red">"test to see if B4 is equal to "X""</span> , <span style="color:orange">"if it's true, return Bronx"</span>, <span style="color:green">"if it's false...</span> <span style="color:red">"test to see if B4 is equal to "R""</span> , <span style="color:orange">"if it's true, return Staten Island"</span>, <span style="color:green">"if it's false, return "Other"</span>)
---
# IF Function - Bonus Round
--
+ Nesting `LEFT` into `IF` combines the "Short Boro" and "Full Boro" columns
--
+ The output from `LEFT` becomes part of the logical test for the `IF` statement
--
+ Try it yourself in a new column titled "Boro"
--
![img-center-100](images/ifbonus.png)
--
## ...is this useful?
???
+ Code for this is:
```
=IF(LEFT(A2)="B","Brooklyn",IF(LEFT(A2)="M","Manhattan",IF(LEFT(A2)="Q","Queens",IF(LEFT(A2)="X","Bronx",IF(LEFT(A2)="R","Staten Island","Other")))))
```
---
class:center,middle
# What did we just do?
???
+ Debrief nested formulas before moving on. What are their reactions? What are the pros and cons?
---
# Inspections by Boro
--
## Let's finish up by making our chart of inspections by boro
--
![img-center-100](images/pivotinspectionboro.PNG)
---
# Your Turn
--
+ You will be working in small groups on the question you chose this morning
--
+ Document your work
--
+ You will be presenting your analysis at the end of the day
--
+ We will be in and out of the breakout rooms to help
--
+ If you need something, raise your hand
--
<br>
<br>
![img-center-100](images/quote.png)
---
exclude: true
# Your Turn
+ Follow the process you outlined
+ Document your work
+ You will be presenting your analysis at the end of the day
+ We'll be here to help
<br>
<br>
![img-center-80](images/quote.png)
---
class:center,middle
# WRAP-UP
???
+ Facilitator reflects with the participants on the foregoing learning
+ Ensure any questions are answered and the paticipants are aware of the material to be covered in next sections
---
class:center,middle
# LUNCH
---
class:center, middle
# WELCOME BACK!
---
# Inspections by Boro - Identifying Top Parks
???
+ Explore what it would take to look at the next level of detail. PROPID is not very friendly. What does it represent? What if we were able to identify the park name from the PROPID?
--
![img-center-90](images/topparks.PNG)
---
name:vlookup
class:center,middle
# How often do you need to combine data from different spreadsheets?
---
# [VLOOKUP](https://support.office.com/en-us/article/VLOOKUP-function-0bbc8083-26fe-4963-8ab8-93a18ad188a1) Explained
--
+ Useful for referencing data from another sheet (reference tables)
--
+ Syntax<br>=VLOOKUP ( <span style="color:red">value</span>, <span style="color:orange">table</span>, <span style="color:green">col_index</span>, <span style="color:blue">[range_lookup]</span>)
--
+ What it Says<br>=VLOOKUP( <span style="color:red">“Find this value”</span>, <span style="color:orange">“In this table”</span>, <span style="color:green">“Once you find it, return its corresponding value in this column number”</span>, <span style="color:blue">“FALSE always”</span>)
--
## TRUE does a fuzzy match, FALSE is an exact match
---
name: vlookup-tips
# Tips for a Successful [VLOOKUP](https://support.office.com/en-us/article/VLOOKUP-function-0bbc8083-26fe-4963-8ab8-93a18ad188a1)
--
+ You will need a common column of data (a reference value)
--
+ Create and title a column for the new data
--
+ Don't trust the Fuzzy Match
???
+ Before going over the tips, ask the group what tips or best practices do they use when joining?
+ Then, go over the tips
---
class:center,middle
# Let's pull the park names from [PIP All Sites](data/PIP_AllSites.xlsx)
???
+ Download All Sites
+ Complete the tips to prepare from last slide: identify common column of data
+ transfer data into same workbook
+ create column for new data
---
# Looking Up Park Name
![img-center-100](images/vlookupfunction.png)
---
# Looking Up Park Name
![img-center-100](images/vlookup_ex_rev.png)
```
=VLOOKUP(A2,'[PIP_AllSites.xlsx]PIP All Sites'!$B$1:$G$6670,6,FALSE)
```
--
## Breaking This Down
--
+ Lookup the value in cell A2
--
+ Match the value in PIP_AllSites Column B
--
+ Return the value in the 6th column of the range
--
+ Don't do any fuzzy matching
???
`=VLOOKUP(A2,'[PIP_AllSites.xlsx]PIP All Sites'!$B$1:$G$6670,6,FALSE)`
---
class:center,middle
# Now we can look at the parks with the most inspections
---
# Parks by Number of Inspections
--
## We could create a pivot chart of all parks
--
![img-center-95](images/pivotparkname.PNG)
--
## ...but that's a lot of information
---
# Identifying Top 3 Parks
--
![img-center-90](images/filtertop10.png)
<br>
--
![img-center-90](images/filtertop3.png)
---
# Identifying Top 3 Parks
## Which doesn't give us much information.
![img-center-100](images/top3overall.png)
---
class:center,middle
# What does the data look like if we filter the top 3 parks inspected in each boro?
---
# Stacked Values
--
+ You can stack values in rows or columns of a PivotTable
--
+ Purpose: to show more information
---
# Top 3 Parks by Boro
--
## Place Boro above Park Name in the Rows quadrant
--
![img-center-100](images/stackedboropark.PNG)
---
# Top 3 Parks by Boro
## Sort largest to smallest for readability
![img-center-100](images/sortdata.png)
---
# Top 3 Parks by Boro
![img-center-100](images/pivottopparks.PNG)
---
class:center,middle
# In case you got a little lost...
# [Click to download Excel Workbook with the formulas we showed](data/PIPData_Formulas.xlsx)
---
class:center,middle
# Any questions?
---
# Data Visualization
> There are two goals when presenting data: convey your story and establish credibility.
##-Edward Tufte
---
# Napoleon's March
![img-center-100](images/tufte.png)
.caption[Image Credit: [https://www.edwardtufte.com](https://www.edwardtufte.com), [CC BY-SA 2.0](https://creativecommons.org/licenses/by-sa/2.0/)]
???
+ What is this visualization showing?
+ What's your critique?
---
class:middle
> Never underestimate your audience. It’s the most common mistake made by presenters. It is not about you anymore. It’s about your audience’s relationship with your content.
##-Edward Tufte
---
# Key Elements to Consider When Designing a Visual
--
+ Type of chart
--
+ Amount of data
--
+ Title
--
+ Use of color
--
+ Data-Ink Ratio
---
# Choosing Your Chart
![img-center-85](images/chartsuggestions.png)
.caption[Image Credit: [Extreme Presentations](http://extremepresentation.com/wp-content/uploads/6a00d8341bfd2e53ef0148c699cc96970c.jpg), [CC BY-SA 2.0](https://creativecommons.org/licenses/by-sa/2.0/)]
---
# Choosing Your Chart
![img-center-85](images/chart_chooser.png)
.caption[Image Credit: [Chart Guide](www.chart.guide), [CC BY-SA 2.0](https://creativecommons.org/licenses/by-sa/2.0/)]
---
exclude:true