Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [replace]

The tag has no usage guidance.

1
vote
2answers
89 views

Replacing data in raster using condition?

I have a raster dataset in ArcGIS displaying altitude. I want to replace all values < 8 with value 8. Other values have to stay the same. How can I do this? I tried raster calculator, but I don'...
3
votes
3answers
263 views

In QGIS replace a '+' with a ', ' for labels

I want to replace a '+' with ', ' to label an attribute looking like "ZT10+ZT20+ZT30" to get "ZT10, ZT20, ZT30" using regexp_replace("zone_nr", '+', ', ') but I get an Eval Error: Invalid regular ...
1
vote
1answer
119 views

python's .replace doesn't work in QGIS' python editor

I am trying to compare some files to a datalist. The datalist's names are all in english letters, while the datafiles have the scandinavian "æ" "ø" "å" letters. an example: the file "Kystnære_måger....
1
vote
2answers
217 views

Replace null pixels from one raster with values from another raster in QGIS

I have 2 rasters of the same area, one has some null pixels and the other one doesn't and I would like to fill in the nulls in raster 1 by values from raster 2. How to perform in raster calculator?
0
votes
0answers
70 views

Nearest neighbour raster values only in specific zone

This is a follow up question to my previous post and someone else's post: I would like to replace NA values in raster with average nearest neighbour values, but ONLY in specific zone of the raster: ...
2
votes
1answer
62 views

Changing raster values in specific zone only

I would like to replace raster values only in specific zone of the raster. Say this is my example raster: library(raster) r <- raster(ncol=1000, nrow=1000) r[] <- runif(ncell(r),0,1) extent(r) &...
1
vote
2answers
491 views

Replace NA's with 0 for large raster data using R?

I want to replace all NA values in a large raster with 0. I found this answer: Replace NA's with 0 for raster data using R? #getting a raster library(raster) f <- system.file("external/test....
1
vote
1answer
29 views

ArcMap correct Errors in Attribute Table

I want to replace the all the -9999 values in my attribute table with 0. Does anyone know an easy way to do this?
1
vote
1answer
65 views

How to use, at one-time, an expression to replace encoding errors in QGIS 2.18.14?

I need to replace several encoding errors in just one task. I have this: If I change the encoding to UTF8, the "Label" field is correct, but the error passes to the other field, "name". Instead of ...
2
votes
1answer
125 views

How to clean data in attribute table in QGIS 2.18.14?

I have a 'name' field with composite name; numbers and words e.g. "1237, Café" I managed extract the part number with Field Calculator and make a new field (see 1) with this expression left( "...
0
votes
1answer
168 views

Adding trailing zeros to specific records in my database

I created a model that automatically adds a field to a database and concatenates the values in two other fields (block & lot) to create my "pin" field called IDNUM. The problem is that when I ...
2
votes
1answer
358 views

Find and Replace ALL function in QGIS field calculator

We are trying to figure out if there is a way to find and replace a "\n" string with the character "-" (hyphen). Excel does a great job finding and replacing all, but not sure how to do same function ...
2
votes
1answer
324 views

Replacing part of raster with another one using ArcGIS Desktop?

I am using ArcGIS Desktop 10.5 and I am unable to find how to replace a part of a raster with another raster. I have a Raster for topography and for a part of it I need to recreate a past morphology ...
3
votes
1answer
275 views

Replacing two characters of field in attribute table using QGIS Field Calculator?

Working in QGIS I have an attribute table containing details of polygons I have digitised, including the two fields, COLUMN_1 and COLUMN_2, each of which is a 4 character Integer that I entered. ...
5
votes
1answer
126 views

How to use Replace function in a custom script?

I would like to use Replace function in a QGIS model but it doesn't work as I wish. I was working with Joseph's brilliant solution (using a custom script in a model) but I couldn't find out how to ...
7
votes
1answer
8k views

Replace NA's with 0 for raster data using R?

I am new in R. How can I replace NA's with 0 for my raster data which have spatial information?