Re: [Qgis-user] Fwd: Question

2020-05-06 Thread Nicolas Cadieux

Hi,

Ok what you want to do is to sample a raster with data points (and not 
merge two rasters).   This mean you have a csv of points and a raster 
with values.  You want the values of the raster to be added to a column 
in the csv.   When you open both layers, do they appear to be well 
placed in space (georeferenced) and one on top of the other?  If not, 
right click on the layer in the layer panel and go to "set CRS/Set layer 
CRS".  Once both layers are in the correct CRS, they should be one on 
top of the other.


Then used the Processing tool (sample raster values) or install the 
Point Sampling tool. Both are plugins that need to be activated under 
the plugins menu but the Point Sampling tool will need to be installed 
first.  You will need to save the CSV in another format because you 
cannot write to a CSV.  Use Shp or better, Geopackage.


Nicolas


On 2020-05-06 10:48 a.m., Nikos Benos wrote:

Dear Nicolas,

I have used the following methodology
https://www.qgistutorials.com/en/docs/3/sampling_raster_data.html
It works fine, but the problem is that the coordinates of the tiff 
file are in different scale than the coordinates of the csv file.
If I convert my csv file (list of points with their coordinates) in 
raster file, how will I combine 2 raster files to produce an excel file?

Thank you very much in advance for your help.

Best,
Nikos

Στις Τετ, 6 Μαΐ 2020 στις 4:36 μ.μ., ο/η Nicolas Cadieux 
mailto:nicolas.cadi...@archeotec.ca>> 
έγραψε:


Hi,

You can save a file and reproject it by changing the coordinates
reference system (CRS).  That would change the coordinates (and
the data dependent on the method used).  However, the is the csv a
vector file (a file with a list of points for example) or is it a
true raster file (a matrix).  If it’s a vector file, you will need
to change it as a raster.  Look for rasterize or « vector to
raster ».  Google it to understand the differences between raster
and vector.

Nicolas Cadieux
Ça va bien aller!


Le 6 mai 2020 à 02:22, Nikos Benos mailto:nbe...@uoi.gr>> a écrit :




-- Forwarded message -
Από: *Nikos Benos* mailto:nbe...@uoi.gr>>
Date: Τρί, 5 Μαΐ 2020 στις 12:25 μ.μ.
Subject: Question
To: mailto:qgis-user@lists.osgeo.org>>


Dear Sir or Madam,

I hope all is well with you. I have converted a png file to a
tiff file (when I attached it to the e-mail, the e-mail became
too big and was not sent). I have been trying to combine the tiff
file with a csv file with no success. The reason is that the
coordinate units are different between the 2 files.
Since I have constructed myself the csv file, is there any way to
transform the coordinate units of the png file to make them
compatible to those of the csv file?
Thank you very much in advance for our help and I am sorry if
this is a vdery simple question, but I am very new to QGIS.

Best regards,
Nikos Benos
-- 
Dr Nikos Benos

Associate Professor
Department of Economics
University of Ioannina
University Campus
45110 Ioannina
GREECE
Tel: +30-26510-05955
Fax: +30-26510-05092
e-mail:nbe...@uoi.gr  


-- 
Dr Nikos Benos

Associate Professor
Department of Economics
University of Ioannina
University Campus
45110 Ioannina
GREECE
Tel: +30-26510-05955
Fax: +30-26510-05092
e-mail:nbe...@uoi.gr  
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org 
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user




--
Dr Nikos Benos
Associate Professor
Department of Economics
University of Ioannina
University Campus
45110 Ioannina
GREECE
Tel: +30-26510-05955
Fax: +30-26510-05092
e-mail:nbe...@uoi.gr  
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Fwd: Question

2020-05-06 Thread qgis-user

  
  
As long as Qgis is set to "Project on the fly" (I think it may be
the default in newer versions), if you load the tiff file first, the
project CRS will be set to the one used by the TIFF file. If you
then load the CSV layer (use add delimited text layer) and in the
dialog specify the correct CRS for the the csv layer.

If you really want to transform the tiff file, open it Qgis, then
right click on the layer and select Export->Save As and set the
CRS to the one you want used (same as the csv file) and save the
raster to a new file.

Or use gdal_transform which was installed with qgis. You will need
to use the command line to do this 
  

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Fwd: Question

2020-05-05 Thread Nikos Benos
-- Forwarded message -
Από: Nikos Benos 
Date: Τρί, 5 Μαΐ 2020 στις 12:25 μ.μ.
Subject: Question
To: 


Dear Sir or Madam,

I hope all is well with you. I have converted a png file to a tiff file
(when I attached it to the e-mail, the e-mail became too big and was not
sent). I have been trying to combine the tiff file with a csv file with no
success. The reason is that the coordinate units are different between the
2 files.
Since I have constructed myself the csv file, is there any way to transform
the coordinate units of the png file to make them compatible to those of
the csv file?
Thank you very much in advance for our help and I am sorry if this is a
vdery simple question, but I am very new to QGIS.

Best regards,
Nikos Benos
-- 

Dr Nikos Benos
Associate Professor
Department of Economics
University of Ioannina
University Campus
45110 Ioannina
GREECE
Tel: +30-26510-05955
Fax: +30-26510-05092
e-mail: nbe...@uoi.gr



-- 

Dr Nikos Benos
Associate Professor
Department of Economics
University of Ioannina
University Campus
45110 Ioannina
GREECE
Tel: +30-26510-05955
Fax: +30-26510-05092
e-mail: nbe...@uoi.gr
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Fwd: Question regarding point to grid analysis

2014-08-12 Thread Mark Coletti
(Just now noticed that by default replies *do not* go to the mailing list.
 Oops.  In any case, Carlos insists that I try the point sampling plugin,
which I'm doing now.  Given that I'm dealing with 5 million points, this
could take a while.)

-- Forwarded message --
From: Mark Coletti 
Date: Tue, Aug 12, 2014 at 4:07 PM
Subject: Re: [Qgis-user] Question regarding point to grid analysis
To: Carlos Cerdán 


On Tue, Aug 12, 2014 at 3:31 PM, Carlos Cerdán  wrote:

> Hi Mark:
>
> I think that "point sampling tool" plugin is the tool what you need, With
> it, you take the corresponding raster value into the points attribute
> table, so in a new column you can calculate difference between point value
> and sampled value and make a statistic analysis of that difference.
>

There are a number of problems with this.  First, you say "take the
corresponding raster value into the points attribute table," which implies
going from raster to vector when I would be doing the exact inverse.  I.e.,
I **start with** vector data to then derive raster data.  Second,
"sampling" has the connotation of taking a subset of values from a larger
set when I want to use **all the values** and not a subset.

I'll make my intent more explicit:


   1. convert point layer P_1 to raster layer R_1 using P_1's attribute M_1
   2. convert point layer P_2 to raster layer R_2 using P_2's attribute M_2
   3. perform measures of similarity between R_1 and R_2

Moreover these constraints must be satisfied:


   - R_1 and R_2 have identical minimum bounding rectangles; i.e., they
   cover the same area
   - R_1 and R_2 have the same cell sizes

The first challenge is noting that there exist many ways of converting a
point layer to a corresponding raster.  E.g., heatmaps, MMQGIS gridify, and
several Processing "Vector -> Raster" algorithms.  The second challenge is
that once I decide on a means of creating a grid layer from vector that
those constraints are satisfied.

I know qgis is capable of doing this task, I just need some pointers on how
to proceed.

Cheers!

Mark
-- 
mcole...@gmail.com




-- 
mcole...@gmail.com
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user