[Xastir] New capability: 2008 Tiger Shapefile street maps

William McKeehan mckeehan at mckeehan.homeip.net
Sun May 3 15:24:42 EDT 2009


I'm not knowledgeable enough about shape files to be able to figure out what
the "where" clause should be.

What I would like to do is pull parts of the shape files into their own file,
so I would have a file (probably still keeping it broken down by state/county)
for Limited Access Roads, another for secondary roads, etc.; basically, the
same breakdown that is done in the dbfawk files. Having each bit of
information in a separate file would let me set the max zoom level for each
file and thus prevent Xastir from reading data that I have no intention of
displaying at the particular zoom level that I am at.

So that's my end goal.

With that in mind, can someone recommend tools that would help me understand
how to build appropriate where clauses to break these files out?

Thanks!
-- 
William McKeehan
KI4HDU
http://mckeehan.homeip.net


On Mon, April 20, 2009 9:38 am, Tom Russo wrote:
> On Mon, Apr 20, 2009 at 07:35:50AM -0400, we recorded a bogon-computron
> collision of the <mckeehan at mckeehan.homeip.net> flavor, containing:
>> This is exactly the information that I was looking for, thanks!
>>
>> One thing that I notice is that when I am at a zoom level that is out pretty
>> far, like 768 or so, it takes a long time for Xastir to run through all of
>> the
>> maps. Much of the map data is repressed by the dbfawk files, but Xastir
>> still
>> has to process it.
>>
>> Is there a way to break out each component from the files, then select max
>> zoom on them in Xastir to allow Xastir to skip them at the file level?
>
> Yes.  See "ogr2ogr" and the "-where" option.  ogr2ogr is part of GDAL.
>
> You can use this tool to extract all the features of one type into a separate
> file with the same signature as the original, so it will use the same dbfawk
> file.  Then you can set map properties to your liking for each such file you
> produce.
>
> If you don't have GDAL installed and want a lighter-weight tool that can
> extract features by attributes from a shapefile, see the trivial
> "split_shape_by_attribute.c" program in my "shape_web" site:
>  http://www.swcp.com/~russo/shape_web/
>
> Follow the link for "Shapefile splitter."  The same section also has the
> syntax
> for getting the job done with ogr2ogr.
>
> The trick would be to construct a where clause that selects the right MTFCC
> codes for the features you want.
>
> --
> Tom Russo    KM5VY   SAR502   DM64ux          http://www.swcp.com/~russo/
> Tijeras, NM  QRPL#1592 K2#398  SOC#236        http://kevan.org/brain.cgi?DDTNM
>   In some cultures what I do would be considered normal.
>                                   -- Ineffective daily affirmation
> _______________________________________________
> Xastir mailing list
> Xastir at lists.xastir.org
> http://lists.xastir.org/cgi-bin/mailman/listinfo/xastir
>
>




More information about the Xastir mailing list