Posts

Showing posts from May, 2024

GIS4102 - Module 2 - Python Fundamentals

Image
 For this assignment, the fundamentals of programming and using strings, string variables to create lines of code, and fix errors in already written code was learned. Using ArcGIS Notebook was how we would test our code as it we would be able to break down each line of code we were writing and see what specific problems were within it. We were tasked to understand lists and create loops. The ultimate goal of this assignment was to create a random number generator, create a while statement to select a specific integer, and to use the remove() method to remove said integer from the lot of random numbers. The image is an example of what was accomplished within this module. The first line being to understand lists and how to find a specific name in a list. After, lines 2-16 were from fixing the previously made code. And lastly, aforementioned the random number generator with an integer removed from the list.

GIS4102 - Module 1 - Python Environments & Flowcharts

Image
For the first assignment in GIS Programming, introductions were made to Python command prompt, IDLE to save and run scripts from files, and ArcGIS Pro Notebook, which runs code like python command prompt, but saves it directly to ArcGIS Pro. The task assigned to us for this module was to understand and work with simple exercises in code such as printing words using commands, and to think like flowcharts. As such, a flowchart on how to convert radians to degrees was made to practice this, as pictured below. This type of thinking will help breakdown steps in creating running code, without overthinking or complicating the process. This also allows observers to understand the process in which the original programmer went through to get the scripts to run.