Master Google Maps, Research WWII and Convert Data

Posted on

As I tooled around the web last week looking for anything useful, interesting or entertaining I came across the following four pages that I thought I would share. Hope you like them.

1. Gizmodo.com – 10 Tricks to Make Yourself a Google Maps Master

Google Maps MasterA great up-to-date look at Google Maps and what it takes to master its ins and outs. The bulk of the article deals with using Maps’ search box. That’s great because the search box is full of great functionality that most users probably don’t have experience with. No matter what your level of skill with Google Maps, there is probably a trick or two to learn here.

2. Worldology.com – World War II: Interactive Map

World War II Map

This is a great little Flash based map that gives you an interactive look at the progression of World War II in the European theater. You can visually see the progression of the war and you can read the popup excerpts as you mouse over the different countries. There is even an option to see current political boundaries overlaid on the map. Cool.

3. freegeographytools.com – Download Page

Free stuff is really neat. Free GIS stuff is even neater. Freegeographytools.com is a nifty little blog that focuses on, you guessed it, free geography tools. The download page provides links to many of these tools like data conversion utilities, KML tools and raster tools. It doesn’t seem like the blog has been updated since 2011. There might be better alternative out there but there is still some good information here.

Five Things I Love About the ESRI Javascript API

Posted on

Having worked with both the ArcGIS Silverlight and Javascript APIs I have to say Javascript has been much more fun. There is just something about working on the front end of a web map and being able to have it do so many amazing things. Here are my top five reasons I enjoy working with this API.

1. Your maps are device independent. Unlike the Flex and Silverlight APIs, Javascript and HTML5 can be viewed on almost any device. The obvious advantage here is that you can reach more people with your spatial data.  Of course having the ability to code for multiple devices means having to customize your code for different screen sizes which can turn into a lot of work. Check out this post from the Treehouse Blog for a great primer on responsive web design.

2. Plenty of code samples and live examples. Code samples are a great way to get your own map up and running quickly without having to figure everything out first. While the samples are not perfect they are a good way to discover map functionality that you might want to incorporate.

3. Support for a ton of layer and data formats. From GeoRSS and GeoJSON to KML and shapefile, this API pretty much covers it.

4. Well written API reference documentation. If you are going to use an API (any API) you want to be able to understand it so you can use it effectively. Good documentation is critical for this. The Esri JS API is (in my own humble opinion) extremely easy to read and understand. Each class has all the information you need to use it without having to decode any meanings. Furthermore, there are links from each class to samples that use it.

5.  Editing tools for online editing of SDE data. Let’s be honest, online editing through a web browser is not a great idea if you are trying to build accurate data. However, there is definitely a place for it. If you are trying to outline an area inhabited by a herd of elk or mark an area of weed infestation, browser editing is probably fine.  It is great just to be able to have this ability so more diverse mapping applications can be developed.

Wow, this list was a lot harder to write than 5 Things I Hate About the ESRI Javascript API. One reason is that there are other APIs out there that do a lot of what the ESRI API does (yes I am thinking about OpenLayers). Another reason is that as I write I think about things I would like ESRI to do better or differently. Oh well, you can’t have everything. Let me know what your thoughts are on the ESRI Javascript API – good or bad.

5 Things I Hate About the ArcGIS Javascript API

Posted on 1 Comment

Building a mapping application with ESRI’s Javascript API is a lot of fun. But it can also be a real pain. Here are five things that absolutely drive me crazy when writing an ArcGIS Javascript map.

1. It is based on Dojo. It’s probably just my lack of Javascript programming sophistication but I find Dojo a little hard to work with. Although the API documentation has improved in recent versions, I don’t find it very intuitive. If you are a beginner or new to Javascript, the getting started documents are just plain frustrating. Ben Farrell thinks there are seven stages of learning Dojo including anger and acceptance. I’m not sure if there are really only seven stages but I can attest to the anger and acceptance.

2. It uses multiple versions of Dojo. Here I go again with the Dojo thing. Half of the developer samples on the ArcGIS.com developer’s site seem to be written pre version 1.7 while the others are post 1.7 and rely on the AMD module format.  I understand that version transitions of supporting libraries can be difficult but this is ridiculous. Since the ArcGIS API updated to version 3.6, many of the developer samples have been updated to show the AMD require format. Unfortunately, the transition has been slow and there is still a lot of mixed version code and a lot of live samples are broken. If you are going to upgrade to a new version of your API, let’s have things ready to go.  

3. No built-in label engine for dynamic, on-screen annotationIt seems obvious to me that the users of a map would want to mark it up with text; especially in conjunction with a draw toolbar. Apparently it isn’t obvious to the ESRI developers. Instead we are left to work with with the labelPoints function which uses the geometry server to create an unseen point and then puts a text symbol on top of it.

4. The label engine problem above leads me to my next gripe. The LabelPoints function doesn’t allow line breaks. That means that if you want to label a polygon with something like, oh say, area and perimeter, you have to have it all on one line or call the labelPoints function twice and use an offset. How about we get the ability to at least use a newline character (\n) and be done with it.

5. No out-of-the-box support for a table of contents. There is a lot of debate about whether an ArcGIS-like table of contents is a good thing in a web map. No matter what side of the debate you fall on, the fact is that people are used to using them and users often want the ability to turn layers on and off. There are a few projects out there that attempt  to solve the problem but each has its own limitation and problems.  It is a little surprising that ESRI doesn’t have a solution for this one yet. Or, maybe it isn’t really that surprising.

I have plenty more gripes with the Javascript API than the ones listed above but I don’t want to get too depressing. Also, I actually enjoy developing with the API (most days) and there are some great things about it. If you want to add to my list put it in the comments.

CSS Shorthand for Clean Web Map Styles

Posted on

I see a lot of CSS code written inefficiently and sloppily, even on official and professional sites. It’s not that the code is wrong, it just could be much better. There is really no reason to have to write four lines of code to set a div tag’s margins or style a tag’s background. You can simply use CSS shorthand to get it all into one compact line.

The reason many people don’t use shorthand is because they’ve never taken the time to learn it. Instead, they lean on verbose style rules that spell everything out.   Below you will find a few common examples of CSS shorthand code that might help you when writing your CSS code. This is in no way a definitive guide. It is simply some of the more common properties you will encounter. You can also download a brief CSS shorthand cheat-sheet.

Margin and Padding:

There are four ways to define the four margins and padding of a CSS box.

  1. margin: [top] [right] [bottom] [left];

    Using four values defines each side individually. For example, margin: 1px 2px 3px 4px; would give an element such as a <div> box a top margin of 1px, a right margin of 2px, a bottom margin of 3px and a left margin of 4px.

  2. padding: [top] [right/left] [bottom];

    This notation relies on the same concept as above but now we only need three values to define our padding. padding: 3% 2% 3%; would give our html element a top and bottom padding of 3% and a right and left padding of 2%.

  3. margin: [top/bottom] [right/left];

    Here we only need two values to define our margins. margin 0 auto; gives a zero margin to the top and bottom and centers the <div> within its containing element.

  4. padding: [top/bottom/left/right];

    A single value defines all sides of an element equally. padding: 1em; applies a 1em  pad to the entire html element.

 

Background:

The background property can be defined by this notation –

background: [color] [url(image url)] [repeat] [attachment] [position];

The color property can be defined using hexadecimal(hex) notation, rgb or color names. The image property is written with the prefix “url” followed by parentheses containing the url to the image you want to use for your background. Repeat is used to tile the background image. If you use attachment you can control whether the background image scrolls with the page or not. Position tells the background image what position to start at on the page. The following is an example of a background:

background: #ffffff url(‘greatpic.gif’) repeat-x fixed center;

 

Font:

The font property can be demonstrated by-

font: [size] [weight] [style] [family];

Font size can be defined with a number and a unit such as px, % or em or with size value words like small, medium, large, etc. Weight is simply the thickness of the font characters. Style refers to the values  italic, oblique, normal or inherit. The family refers to the font family like Serif, Georgia or Helvetica. Here is an example:

font: 1em normal italic Helvetica;

 

Border:

Border properties are relatively simple-

border: [width] [style] [color];

The border of an html element is easy to style. You just need to designate the width, color and style. Width can be written using pixels or the pre-determined width designations thin, medium and thick. Style refers to values like solid, dotted and dashed. Color is written the same as in the background property and can be a hex number, rgb numbers or a written color.

border: 2px solid blue;

 

There are a lot more shorthand properties for CSS. Even some of the ones I posted above have further properties that could be included. For a more complete look at CSS shorthand methods check out this page from Mozilla.

Jump Start Your Geospatial Career with This Free E-book

Posted on

It’s a great time to be a GIS professional. There are no shortages of jobs and the field keeps changing and expanding to include amazing technologies and applications. However, with increasing demand often comes increasing competition. Anyone who wants to enter the geospatial field or advance in it needs to pay attention to fast changing industry needs and make sure they are positioned to fill those needs.

The folks over at DirectionsMag.com have put together a collection of articles dealing with topics of interest to all levels of the geospatial community. It is called GIS Jobs, GISP Certification and Geospatial Careers and can be downloaded at

http://www.directionsmag.com/books/gis-jobs-gisp-certification-and-geospatial-careers/347075.

It is a great little PDF e-book covering things from GIS job interviews to issues surrounding certification. Have a look, it’s free.

 

Easily Export ArcGIS Attribute Table to CSV

Posted on 9 Comments

For many ArcGIS users, exporting an attribute table to a .csv file or excel format file is a common part of their workflow. Unfortunately, exporting to either of these formats has never been a core functionality of ArcGIS. To overcome this you typically have had two choices: write a script using third party libraries or go through multiple steps exporting to a .txt file and converting it to .csv or .xls.

However, there is a little shortcut you can take to quickly export your data to .csv right from the attribute table.

  • From the table, click Export.
  • Under “Output Table” browse to the folder you want to put your .csv file in, save type as .txt and enter a name for your output making sure to leave off the ‘.txt’ from the end of the name.
  • If the ‘.txt’ extension is present in the name the tool will output a normal text file of your data. If, however, your name does not include the ‘.txt’ extension then your output will be a .csv file by default.

4 Essential Maps to Have in an Emergency

Posted on
Essential Maps for Emergencies

September is National Emergency Preparedness month. Every year throughout the United States there are fires, floods, storms, earthquakes, industrial accidents and even explosions. Sometimes these situations are contained to a small locality where they are easily managed. Other times, emergencies cover large geographic areas and impact the lives of thousands of people. Maps, imagery and GIS have become increasingly important in preparation for and management of emergency situations at federal, state and local levels.

But geospatial tools in an emergency are not just for organizations like FEMA and public safety departments. Individuals have access today to numerous map resources and they could be using them as insurance in the event that a natural or man made disaster should strike in their area. Below are four maps that could give you the upper hand in such a situation.

Home Floor Plan

Every home needs an evacuation plan. A simple pencil sketch of your house will do as you really just need to show the walls and where doors are located. If you want to get more detailed you could use an online floor plan creator like Autodesk Homestyler. Homestyler lets you build detailed, multi-level, 3D floor plans of your home’s interior.

Current Printed Street Map

Google Maps are great for finding the shortest distance by road between locations. Along with other mapping applications like Bing Maps and MapQuest, Google Maps are a good first choice for routing yourself or others to safety. However, you always have to remember that in an emergency situation, Internet and/or cell reception could be disrupted. For this reason, among others, having a printed street map of the city you live in and the surrounding area is a good idea.
Street maps can often be purchased through organizations like AAA or in many gas stations located near the entrances to your city. The local chamber of commerce or visitor center often has maps for free or a low price or they can give you further advice on where to go to get a map. It is true that it is getting harder and harder to find good printed paper maps these days but they are still out there.

Safety Map

Maps are great if you know where you want to go. But in an emergency, unless you have a destination in mind of where you can find help or can meet up with loved ones, a map just shows you many ways to nowhere. At Safety-maps.orgyou can take care of the problem.
            Safety Maps is a free online tool that helps you plan for this situation. You can use it to choose a safe meeting place, print a customized map that specifies where it is, and share this map with your loved ones.
Safety-maps.org is a great site that is simple to use but serves a great purpose. Making a safety map is extremely easy. You just search for the area you live in (I used a zip code), position a green cross hair on the place designated for meeting and type a message or directions. Then you create your map and print it. You can fold several copies of the map for different people in your family so each will have one no matter where they are or what the situation.

US Road Map

Having a major roads map (or a US road atlas) can help you relocate once you are out of your local area if you need to evacuate quickly. A national level map is also handy for determining the location of disasters outside of your area. Rand McNally is one of the best known makers of quality road atlases.
There you go, four maps that could mean the difference in surviving an emergency situation. Are you prepared? Are there any you would add?

Could GIS be Killing You?

Posted on
If you are a GIS professional there is a good possibility that you are slowly shaving time off your lifespan. What is this malady you might ask, and can it be prevented by moving to open source? If only it were that simple.
Several studies have shown that sitting for long periods of time can increase a person’s chances of dying from a heart attack by more than 50%. That is a scary fact that should get you thinking about what you can do to prevent it. Here are a couple of things you can do right now to reduce the risks associated with a sedentary job:
Sitting Kills
  1. Stand up! At least try to as much as possible. While the effects of sitting can be cumulative, interrupting your sitting periods can be beneficial.
  2. Use a standing desk. If you are in a work environment that will permit it, standing to do your work can make you feel better, make you burn more calories and of course and take care of the “sitting is bad” for you problem. If the cost of a standing desk is not something your employer will consider, you can always raise your monitors and keyboard with books or other objects.
  3. If you’re stuck using a regular desk you can always use a DeskCycle under the desk. This will keep your legs moving and blood circulating. Your rate of calorie burning will increase as well.
  4. Sit on an exercise ball. They are great for strengthening the lower back and you can always fall back into a couple of sit-ups when the fancy strikes.
  5. Collect GIS field data. If GPS data collection is part of your organization’s workflow, see if you can add that into your schedule a couple of times a week. You will be moving, burning calories and staying healthy.
  6. Exercise at your desk. You can red this DIYLife article to get some great ideas for keeping your body in motion throughout the day.
The lesson to take away from this is to keep moving. Regardless of you office situation there are probably things you can do to put a little motion into your day.

AFCEA Tracks Geospatial Intelligence

Posted on

The Armed Forces Communications and Electronics Association (AFCEA) is a non-profit organization dedicated to serving military, government, academia and private industry. The association’s name centers on communications and electronics but under this broad umbrella are many varied disciplines and professional fields represented.

One such field is information systems technology. The April 2012 issue of SIGNAL, AFCEA’s monthly news magazine takes a closer look at geospatial information systems and their impact on today’s intelligence gathering efforts. While the articles in the current issue focus on the use of GIS for military intelligence gathering, they are useful for GIS users in all GIS communities. Developments, technologies and trends that begin at a national level often morph into public oriented applications that benefit downstream users. You can read the current issue of SIGNAL online and discover the other free tools AFCEA offers of their we site like their blog and e-newsletter.

Membership in AFCEA was once the privilege only of members of the military. Today, anyone with an interest in technology can join and take advantage of benefits like networking opportunities, educational discounts and product discounts through Dell and HP.

I have been a member of AFCEA for over four years now and consider it a top notch professional organization. Check it out and let me know what you think.

When GIS Becomes a Chore

Posted on
River in Colorado

I just got back from a week-long trip to one of the last corners of Colorado without smoke filling the air. It was a great time of rock hunting, gold panning, hiking and just spending time with family.

 

In a typical work-week I will be on the computer for around eleven hours a day, however, throughout the entire week in Colorado I never went on a computer. On the drive back home the realization of how much I did not want to go back to it hit me.
It’s not that GIS work or following blogs and social media are not enjoyable activities because they are. The mix of logical problem solving through analysis and the creativity of cartography are hard to beat in any career field. I enjoy designing useful tools and providing engaging and helpful products for my employer. I also have a good time writing RyanRandom.com and keeping up with other blogs and Twitter.
The problem is that my job and online activites at home have become either boring and routine or overly time consuming. It is easy to fall into the routine of data maintenance at the day job which can make it seem boring or monotonous. Of course there really is data to maintain but my workplace is an environment that encourages innovation and learning. I need to capitalize on this.
When I get home I feel the need to throw myself into extra online activities (perhaps to compensate for my lack of interest at the office?). But what I usually end up doing is reading blogs more than writing them or just lurking places instead of being productive. When I do this I am wasting time that could be spent better elsewhere like with my family, learning a new skill or even getting enough rest.
So what can be done about a situation like this? I came up with the two lists below to help. The first list of five actions will be applied to my work situation. The second list of five actions are things that can be done at home to still be productive without being destructive.

On the Job:

  1. Find new angles to attack problems and try to incorporate new tools that can accomplish the task in a different way. There is no reason to be bored doing what I am doing even if some of my tasks are repetitive.
  2. Improve my cartography skills. No matter how effective your maps seem today, there is always room for improvement. There is a ton of great advice out there on improving cartography skill like GIS Cartography: A Guide to Effective Map Design by Gretchen Peterson.
  3. Start scripting and automating more with Python. Also, learn more programming languages that could make working easier and more fun.
  4. Participate more in the GIS community to gain insight and help from others.
  5. Utilize blogs and Twitter to solve more technical problems rather than stewing over them longer.

At Home:

  1. Put God and family first when I get home. The kids will only be the age they are now, right now. Spending time doing what matters most should be my priority; if it’s online, it does not matter most.
  2. Spend less time on the computer but accomplish more. Become more productive.
  3. Make goals before sitting down to work and get off the computer when done.
  4. Move slower and stop trying to do so much. You do not need to wear your body and mind out to be productive.
  5. Get more sleep and exercise.
Does anybody else suffer from work boredom and self-overwork at home? What are some of your solutions? I would love to hear them.