- 20
- 31 194
Green Numbers
United States
Registrace 31. 03. 2021
Welcome to Green Numbers Data Tutorials! I have enjoyed a career in data science as an epidemiologist and informatician for 15 years in state government, university, and the pharmaceutical industry. With this channel I'm excited to demonstrate what I've learned and to learn a few new things along the way. I have a lot of experience using SAS and I'm also very interested in python, so my focus will be in those areas. I also plan to demonstrate practical skills using MS Excel and Access as well. I hope you'll let me know what you'd like to see in future videos.
How to Geocode in Python Using the Census API | Data Tutorial | Python
In this Green Numbers data tutorial I show you how to use the census API to geocode a list of street addresses and read the returned values in a pandas dataframe.
The Census Bureau provides a API that allows you submit a list of street addresses and receive geocoded values in return. Those values include the latitude, longitude, state FIPS code, county FIPS code, census tract, and census block.
There’s a lot of documentation that describes the format of the address file you need to submit, instructions for submission such as selecting the time period when the address range was captured, and the format of the file you receive in return. You can find links to this information in this video’s description.
In this video I’m going to show you:
-what the street address file should look like,
-how to use the API in python to submit the file,
-and how to read the returned data into a pandas dataframe.
github.com/greennumbers/python
www2.census.gov/geo/pdfs/maps-data/data/FAQ_for_Census_Bureau_Public_Geocoder.pdf
www.census.gov/programs-surveys/geography/technical-documentation/complete-technical-documentation/census-geocoder.html
geocoding.geo.census.gov/geocoder/Geocoding_Services_API.pdf
geocoding.geo.census.gov/geocoder/geographies/addressbatch?form
The Census Bureau provides a API that allows you submit a list of street addresses and receive geocoded values in return. Those values include the latitude, longitude, state FIPS code, county FIPS code, census tract, and census block.
There’s a lot of documentation that describes the format of the address file you need to submit, instructions for submission such as selecting the time period when the address range was captured, and the format of the file you receive in return. You can find links to this information in this video’s description.
In this video I’m going to show you:
-what the street address file should look like,
-how to use the API in python to submit the file,
-and how to read the returned data into a pandas dataframe.
github.com/greennumbers/python
www2.census.gov/geo/pdfs/maps-data/data/FAQ_for_Census_Bureau_Public_Geocoder.pdf
www.census.gov/programs-surveys/geography/technical-documentation/complete-technical-documentation/census-geocoder.html
geocoding.geo.census.gov/geocoder/Geocoding_Services_API.pdf
geocoding.geo.census.gov/geocoder/geographies/addressbatch?form
zhlédnutí: 1 917
Video
5 Useful SAS Character Functions | Data Tutorial | SAS Functions
zhlédnutí 556Před 3 lety
In this Green Numbers data tutorial I show you five useful character functions in SAS: COMPRESS, SCAN, SUBSTR, CATS/CATX, and TRANSLATE. See the links below for more examples and modifiers. documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/n0fcshr0ir3h73n1b845c4aq58hz.htm documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lefunctionsref/p0jshdjy2z9zdzn1h7k90u99lyq6.htm support.sas.com/r...
Using Macro Code If-Then and Do Loops in SAS | Data Tutorial | Macros
zhlédnutí 3,7KPřed 3 lety
In this Green Numbers data tutorial I show you how to use macros in SAS. With macros you can make your code more reusable and flexible. Reusing code can save you a lot of time and reduce clutter. Macro programming can seem daunting at first, especially if you’re new to programming, but if you focus on and practice the basics and build out from there, I promise you’ll find this skill very reward...
Creating and Using Macro Functions in SAS | Data Tutorial | Macros
zhlédnutí 896Před 3 lety
In this Green Numbers video I show you how to use macros in SAS. With macros you can make your code more reusable and flexible. Reusing code can save you a lot of time and reduce clutter. Macro programming can seem daunting at first, especially if you’re new to programming, but if you focus on and practice the basics and build out from there, I promise you’ll find this skill very rewarding. Thi...
3 Ways to Create Macro Variables in SAS | Data Tutorial | Macros
zhlédnutí 623Před 3 lety
In this Green Numbers video I show you how to use macros in SAS. With macros you can make your code more reusable and flexible. Reusing code can save you a lot of time and reduce clutter. Macro programming can seem daunting at first, especially if you’re new to programming, but if you focus on and practice the basics and build out from there, I promise you’ll find this skill very rewarding. Thi...
Importing a CSV file into a Python Pandas dataframe | Data Tutorial
zhlédnutí 1,2KPřed 3 lety
In this Green Numbers data tutorial I show you how to read a comma delimited file to a python pandas dataframe. www.anaconda.com/products/individual
Converting Numeric to Character in SAS | Data Tutorial | PUT Function
zhlédnutí 2,7KPřed 3 lety
In this Green Numbers data tutorial I show you how to convert a numeric variable into a character variable. Why might it be necessary to do this? One common reason is to concatenate two or more datasets that have different data types. This happens a lot when you import multiple datasets from Excel. Another reason to convert numeric to character is to add leading zeroes for numeric values that a...
Concatenating String Variables in SAS | SAS Tutorial
zhlédnutí 1,3KPřed 3 lety
In this Green Numbers video I show you how to concatenate character variables in SAS. There are lots of use cases for concatenating, or combining, text variables into one variable. For example, you might need to combine a first name variable and a last name variable to create a full name variable. I’m going to show you several ways to do this.
Using Regular Expressions in SAS | Extracting a Value using Regular Expression | PRXSUBSTR | PRXPOSN
zhlédnutí 1,5KPřed 3 lety
In this Green Numbers video I show you how to use regular expressions to make your code more flexible. In coding we often need to search for specific strings, and there are functions that help us to do this such as the FIND function. But what if you’re not looking for a specific string value but a string pattern. For example, rather than a specific phone number you’re looking for any phone numb...
Using Regular Expressions in SAS | Find and Replace a Pattern | PRXCHANGE
zhlédnutí 2KPřed 3 lety
In this Green Numbers data tutorial I show you how to use regular expressions to make your code more flexible. In coding we often need to search for specific strings, and there are functions that help us to do this such as the FIND function. But what if you’re not looking for a specific string value but a string pattern. For example, rather than a specific phone number you’re looking for any ph...
Using Regular Expressions in SAS | Match a Pattern | PRXMATCH
zhlédnutí 2,2KPřed 3 lety
In this Green Numbers data tutorial I show you how to use regular expressions to make your code more flexible. In coding we often need to search for specific strings, and there are functions that help us to do this such as the FIND function. But what if you’re not looking for a specific string value but a string pattern. For example, rather than a specific phone number you’re looking for any ph...
Working with Dates in SAS | Data Tutorial | INPUT Statement
zhlédnutí 1,5KPřed 3 lety
In this video I show you how to work with dates in SAS. I describe how SAS views a date in numeric format, how to create a date in numeric format, how to convert a date from character to numeric format, and demonstrate a way to automate today's date.
Converting Character to Numeric in SAS | Data Tutorial | INPUT Function
zhlédnutí 6KPřed 3 lety
In this video I show you how to convert a character variable to a numeric variable in SAS. I demonstrate using the INPUT statement but I also demonstrate some shortcuts and show how to selectively convert character values to numeric.
Using Arrays in SAS | Data Tutorial | Do Loops
zhlédnutí 847Před 3 lety
In this Green Numbers data tutorial I show you how to use arrays to simplify your coding and make it more efficient. In coding we do repetitive things all the time. For example, I routinely need to standardize my text variables to make them easier to compare, by making them uppercase, removing punctuation, and getting rid of leading and trailing spaces. But you may also need to modify numeric v...
Using SQL to Create Macro Variables in SAS | Data tutorial | PROC SQL
zhlédnutí 790Před 3 lety
In this Green Numbers data tutorial I show you how to use SQL to create macro variables to make your coding more efficient. Because SQL is great for aggregating, it’s a great tool for generating lists. In each example, I show you how to create the macro variable then show you how the variable can be used. I start simple then get progressively more complex.
Summarizing Data using SQL in SAS | Data tutorial | PROC SQL
zhlédnutí 259Před 3 lety
Summarizing Data using SQL in SAS | Data tutorial | PROC SQL
Using SQL to join data in SAS | SAS Tutorial | PROC SQL
zhlédnutí 179Před 3 lety
Using SQL to join data in SAS | SAS Tutorial | PROC SQL
Intro to SQL in SAS | Data tutorial | PROC SQL
zhlédnutí 195Před 3 lety
Intro to SQL in SAS | Data tutorial | PROC SQL
Thanks so much! I have been looking for this kind of videos for a long time ! Please keep going and it is very helpful and clear the way you are teaching !:) good job
Solved my issue at the 3rd example. Thanks a lot
Hope I see your more videos, SAS MACRO SQL etc. SAS Studio if possible.
Best!
Best of best! 😊
Just amazing , so informative!
Best!!!
Thank you for the informative videos.
Spot on video on regex, thanks so much for making this concepts clear.
Super teaching how to get code any github you have
I have a character date(2006-10-23T15:34) So i used datetime. informat to convert to numeric but it's not working Can you give me a solution....
Very informative
How to match if the value is like 01MAR2020?
Great explanation, thank you very much!
Hello sir, this video is really useful....We are expecting more videos.
Thanks for this video. I cut my data clearing and coding teeth on PRXMATCH functions but most of the PRXChange literature (SUGI papers etc) didn't make sense to me because they would always seem to skip over the basic 's/ match/ change /' intro. You had it sorted for me in about 45 seconds and I was moving forward with robust code.
Amazing video
thanks a bunch...this is so clear and well done! it really makes things easy...macros can be so tangled up sometimes...
This is good content
Love this. Thank you!
Really good examples, thank you!
The census batch geocoding API seems to be painfully slow on my end. Is that what you find as well? At the moment, I'm trying to geocode in groups of maybe 700 and it has already taken more than 5 min and I have yet to get a response. I've used the censusgeocode package as well, and that also takes so long that it is un-usable, in my opinion. Any suggestions as to how it could be sped up?
Hi there! I'm facing a similar issue, have you found any better ways to do such conversions? Thanks!
@@yongyanyue7165 I switched to geocoding through the ArcGis API and that was considerably faster. It does cost $ but if you setup the right kind of account and only geocode what is necessary, then it's pretty cost effective.
In Example 2 NUM_2 has a dollar.8 format, yet the output shows the number without the dollar sign. Is it not supposed to show as currency?
Great video as always. Might be worthwhile to mention what the modifiers mean exactly. For example that the "k" means keep.
Excellent intro to SAS!
very nice video! very well explained and with excellent tips.
your regex videos for sas are really a treasure!
awesome video, super well done