<div dir="ltr"><div><div>Perhaps raster calculator can also help you<br><br>Expression:<br><br> (layer>0 and layer <= 1)<br><br>Gives us 1 when sentence is true and 0 for false, for each cell in "layer".<br>
<br></div>Good luck<br><br></div>Carlos<br><div><div><br><br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014-04-10 9:29 GMT-05:00 Micha Silver <span dir="ltr"><<a href="mailto:micha@arava.co.il" target="_blank">micha@arava.co.il</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
    
  
  <div style="direction:ltr" bgcolor="#FFFFFF" text="#000000">
    <div>Using GRASS there are two modules you
      can consider. First :<br>
      v.to.rast in=... out=... type=point use=val value=1<br>
      will convert points into raster cells (at the current region
      settings), where any cell that contains at least one point will be
      given value 1.<br>
      <br>
      Next:<br>
      r.in.xyz in=... out=... method=sum <br>
      will create a raster (at the current region settings) where each
      cell will have a value = the count of points in that cell.<br>
      <br>
      HTH,<br>
      Micha<div><div class="h5"><br>
      On 04/10/2014 04:20 PM, Colin D. MacLeod wrote:<br>
    </div></div></div>
    <blockquote type="cite"><div><div class="h5">
      <div dir="ltr">
        <div style="font-size:12pt;font-family:'Calibri'">
          <div>Hi All,</div>
          <div> </div>
          <div>I’m a fairly experienced GIS user, but I’m new to QGIS.
            I’m using version 2.2, and I’m trying to convert a point
            data layer into a raster data layer using the Rasterize
            tool. The point data layer has an integer field with a value
            of 1 for all records, and I want to make a raster data layer
            which has a value of one for each cell which has at least
            one point in it (some cells have more than one point in
            them). When I use the Rasterize tool, it creates the raster
            data layer fine, but all cells with have points in them
            appear to have a value of 0.995968. I’ve tried editing the
            gdal code (even making the resulting raster data layer an
            integer layer), but I still cannot get it to produce a
            raster with a value of 1 rather than just a number very
            close to one. </div>
          <div> </div>
          <div>Does anyone have any suggestions of where I might be
            going wrong and/or how to solve this issue?</div>
          <div> </div>
          <div>On a related note, is it possible to use the Rasterize
            tool to work out the average or total values for all the
            points which fall in each grid cell? If so, how (I can’t
            find anything in the gdal instructions themselves which
            would suggest this is possible, but I might be missing
            something). If this isn’t possible to do with the Rasterize
            tool, are there other tools in QGIS which can do this?</div>
          <div> </div>
          <div>Thanks for any help anyone can give on this.</div>
          <div> </div>
          <div>All the best,</div>
          <div> </div>
          <div>Colin</div>
          <div> </div>
          <div style="font-size:12pt;font-family:'Calibri'">==================================================================================<br>
            GIS IN ECOLOGY - Providing Training, Advice And Consultancy
            On The Use Of GIS In Ecology<br>
            <br>
            Web: <a href="http://www.GISinEcology.com" target="_blank">www.GISinEcology.com</a> Email: <a href="mailto:info@GISinEcology.com" target="_blank">info@GISinEcology.com</a><br>
            <br>
            Need to ask a question about using GIS? Try the GIS In
            Ecology Forum: <a href="http://www.GISinEcology.com/GIS_in_Ecology_forum.htm" target="_blank">www.GISinEcology.com/GIS_in_Ecology_forum.htm</a><br>
            <br>
            Books From GIS In Ecology Staff:<br>
            <br>
            An Introduction To Using GIS In Marine Biology; RRP: £44.99<br>
            An Introduction To Using GIS In Marine Biology:
            Supplementary Workbook One - Creating Maps Of Species
            Distribution; RRP: £19:99 <br>
            An Introduction To Using GIS In Marine Biology:
            Supplementary Workbook Two - Working With Raster Data
            Layers; RRP: £19.99 <br>
            <br>
            If you wish to purchase these books, visit:
            <a href="http://www.gisinecology.com/Book_Shop.htm" target="_blank">http://www.gisinecology.com/Book_Shop.htm</a><br>
            <br>
            To help the environment, please do not print out this email
            unless it is unavoidable.<br>
==================================================================================</div>
        </div>
      </div>
      <br>
      <br></div></div>
      This mail was received via Mail-SeCure System.<br>
      <br>
      <fieldset></fieldset>
      <br>
      <pre>_______________________________________________
Qgis-user mailing list
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a>
This mail was received via Mail-SeCure System.


</pre>
    </blockquote>
    <br>
  </div>

<br>_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br></blockquote></div><br></div>