1

In arcGIS 10 I have worked on a number of raster files, from which I have created one large table by using the Zonal statistics as Table Tool. I have a result as shown below (I have more than 70,000 rows, thus only showing the first 9 here):

OID LO  MAG PCR WAT SVE ARA GRA FOR MHF     B13 B12 MTP BI6 BI4     ALT
1   1   0   0   0   0   0   0   0   32.00   100 420 43  72  4821    18.18
2   1   0   1   0   0   0   0   0   39.17   99  421 81  72  4886    20.14
3   1   0   0   0   0   1   0   0   29.25   112 474 13  74  4947    132.80
4   1   0   0   0   0   0   1   0   35.98   114 485 4   70  4997    166.54
5   1   0   0   0   0   0   0   0   39.21   104 438 3   74  4859    54.82
6   1   0   0   0   0   0   1   0   40.45   109 454 3   68  4971    107.65
7   1   0   0   0   0   0   1   0   41.81   107 435 2   69  4909    46.70
8   1   0   0   0   0   1   0   0   49.78   105 427 21  70  5009    18.36
9   1   1   0   0   0   0   0   0   53.00   106 427 98  70  5173    13.33

I have created this table because I needed to do a regression analysis, explaining the presence/absence of LO by my explanatory variables (all but OID and LO). Now, I need to export each of my variables (LO, MAG, PCR...) as ASCII files, all with the same extent and cell count, in order to analyse them further in a different program. This means I need raster files again, to convert raster to ASCII. But as my original raster datasets are different in both extent and resolution, I figured it would probably be easiest to convert my table into different raster datasets. In that way, all my datasets would contain the same number of cells. I have however tried myself, and searched online, finding no clues as of how to do this.

Does anyone know if it is possible to create raster files from a table?

I have already tried to give each of my individual raster dataset the same extent and cell size, with no luck. I have tried clipping my raster (using both Maintain clipping extent and Use input feature for clipping geometry), but it still creates raster with different number of rows and columns.

I am unable to give my raster files the same extent.

3

The results of zonal stat is one line per unique value in your raster, so this cannot be converted into a new raster without information about the position of each value.

What you can do is joining your table with the original raster with zone values and then work on it. Make sure that you first "build raster attribute table" in order to do the join.

  • Thank you so much for the reply. I have one small problem, however. When I build my raster attribute table, for instance for the original MAG raster, I get an attribute tale with the values 1 and 0, and a count for each of them. The total count is my total number of rows in the table. I do not get a table of 70,000+ rows with 0 and 1 listed. Thus when I join the table to the MAG raster (Join Field), I only get two rows. Do I use the wrong Join-Tool? Or can I build my Raster Table differently to get 70,000 rows instead of 2? – LHAndersen Apr 11 '16 at 10:05
  • I meant to join on the zone raster, not on one of the value rasters used in the zonal stat. – radouxju Apr 11 '16 at 12:55
0

Use lookup in reclassify toolbox to convert your zones raster to floating point raster. Export it ASCII afterwards

  • I have tried using the Lookup Tool, followed by the Raster to Floating point Tool. When I use the Lookup Tool for each of my different original raster datasets, I get raster files that still contain a different number of rows. Is there a way to specify the number of floating points to be created afterwards by the Raster to Float tool? If this is the case, maybe it would be possible to create raster of the same extent by choosing that each should consist of the same number of floating point? – LHAndersen Apr 11 '16 at 10:15
  • Define fixed Extent, cell size and snap raster using environment settings – FelixIP Apr 11 '16 at 18:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.