Questions tagged [data-frame]
A map element that defines display properties for one or more layers in ArcMap.
156
questions
0
votes
0
answers
16
views
Spatial join for checking whether a coordinate lies within a shape polygon
I've a database of coordinates that records lat,lon values in 2 separate columns as double.
I'm trying to map these points to polygons within my shapefile using geopandas spatial join, but I keep ...
1
vote
1
answer
49
views
Tilting shapefile so it appears flat or seen on its edge
I don’t know exactly how to explain what it is I am trying to do so I will have to resort to a couple of pics. Hopefully that will explain it for me. I am trying to ‘tip’ shapefiles so that they are ...
0
votes
0
answers
13
views
New data frames in ArcMap only allow ability to adjust size by grabbing corners, not with edges of polygon
Whenever I create a new data frame in ArcMap 10.8.1 I am able to adjust the extents of the data frame by the corners as well as the edges which is very useful for lining everything up in layout view.
...
0
votes
0
answers
39
views
Incorrect number of dimensions in creating multiple plots using a for loop with ggplot2
I'm trying to map out all these different "solutions" from the prioritize model using ggplot. (To preface I'm very new to R so perhaps my code/methods are extremely rudimentary and why I'm ...
5
votes
2
answers
560
views
Joining two Pandas DataFrames based on lat, long as fields
I have two Pandas DataFrames containing "lat" and "long" coordinates. I'd like to do a spatial join and merge columns from one DataFrame into another.
import pandas as pd
df1 = pd....
3
votes
3
answers
773
views
Reverse geocoding of Pandas DataFrame with Lat/Long columns
I have a DataFrame with Lat/Long coordinates in separate series. I am trying to use GeoPy and Nominatim to get the reverse raw address. I keep getting errors such as:
TypeError: reverse() takes 2 ...
1
vote
1
answer
61
views
Re-projecting shapefile in R that has class of character
I am trying to project a shapefile of the world that was downloaded from naturalearthdata.com
shp is a shapefile of the worlds landmasses that I downloaded. When I use the code class(shp)
R tells me ...
0
votes
1
answer
68
views
ggplot - error data must be a data frame [closed]
Why do I have this error in my R code?
0
votes
1
answer
614
views
Cannot coerce class to a data.frame
I'm using R to run a random forest to predict the distribution of sediment classes in a study area. I have a .csv of the locations where sediment has been sampled, and rasters of all my predictor ...
0
votes
1
answer
800
views
Dataframe object is not callable
I have a dataset contains latitude, longitude and temp. I tried to draw a contour map of temp based on latitude and longitude on the world map. I need to mark the contour line intervals also in the ...
1
vote
0
answers
19
views
How can I let R recognize my mosaic as a data frame so I can use the ggplot2 package in R
I have various climate projections for different values such. I extracted the certain values I needed using the brick function. Afterwards I took the average using the mosaic function. I want to use ...
0
votes
1
answer
43
views
Exporting data frames in layout into unique PDF for each using ArcMap
I have an MXD with 2 data frames.
How can I export each Dataframe as a separate PDF?
2
votes
2
answers
142
views
QVariant error when converting DataFrame into attribute table using PyQGIS
I have a df which looks like that:
ID
Happy
0
Very
1
Little
I'm trying to convert it into an attribute table:
headers = [col for col in df.columns]
fieldlist = QgsFields()
fieldlist.append(...
0
votes
0
answers
36
views
Updating layer in corresponding data frame in single MXD in ArcPy
I have a shapefile and a layer file. In the shapefile, I am updating the last column using a .dbf file, which has numeric values. So, the last column of the shapefile will be updated five times and I ...
1
vote
0
answers
38
views
Extract time series from CFSV2 Google Earth Engine Python
I'm trying to export to a dataframe the time series of the CFS model for the maximum temperature since 2000 for any latitude/longitude, but I have a Time Out problem. So, I tried a for each year and ...
1
vote
1
answer
38
views
Iterating and updating through feature class fields based on DataFrame using ArcPy
I am updating mismatched data across two systems and have an Excel sheet that combines a consolidated data set. Unfortunately I do not have a reliable join field to relate this back to my GIS data.
I ...
2
votes
2
answers
527
views
Appending DataFrame to existing layer in GeoPackage
I have scripts to download and extract two shapefiles every 24 hours and create a cleaned DataFrame. I want to append the DataFrame for each one to a specific layer in a gpkg. The only example I can ...
0
votes
0
answers
438
views
ValueError: 'ITEM' is both an index level and a column label, which is ambiguous
I'm trying to process some data, with geopandas0.9.
Here is my code:
locations = select_polygons.groupby(class_col).apply(lambda x: \
sample_locations_from_polygon(x, sample_on_boundary='...
0
votes
1
answer
26
views
Exporting 3 layers together as JPEG using Data Driven Pages
I'm trying to use data driven pages to export JPEGs of features that share a common attribute.
E.g. I have two point layers, "beach" and "light". And a polyline that connects them, ...
1
vote
1
answer
427
views
Placing multiple data frames in a single map layout in ArcGIS Pro
I am trying to prepare a layout for my study area by method showing country to state to city in ArcGIS Pro, but all the data frames are showing the same area and when I try to change the data, the ...
1
vote
1
answer
464
views
Transform Google Earth Engine script to Python with Landsat 8 temporal data
I am doing a study for my work and I need to adapt my Google Earth Engine script in Python, but I am encountering some problems.
Here is a Google Earth Engine script:
//Importing image and geometry:
...
2
votes
1
answer
343
views
Create one id variable for each dataframe in a list of dataframes with name of each dataframe
I have a list of dataframes. For each dataframe I want to create one new variable or column called uniqueid and I want this unique id to be the name of the dataframe from the list. I have tried the ...
-2
votes
1
answer
92
views
How to change column value by matching row value in data frame?
Say I do have the following table
| longitude | latitude | temperature | label |
|-----------|----------|-------------|-------|
| x | y | z | 1 |
| p | q | ...
1
vote
1
answer
68
views
Exporting data frame as PNG after adding Layer File using ArcPy in ArcMap
My question relates to the answer found at Exporting data frame as PNG in ModelBuilder using ArcMap
I've followed the steps in the answer provided by @PolyGeo, but my output PNG is just a blank image.
...
2
votes
2
answers
152
views
Getting names and numbers in specific vectors from a dataframe in a loop R
I have a huge DataFrame, in which I need to extract some information that generates filenames that I need to search in my working directory later, I also need the value in each cell of the pixel ...
2
votes
2
answers
174
views
Selecting attributes by coordinates from DataFrame in Python
I wonder how to return the right information needed from this df. Currently I get an empty return. I think the problem is my selection because the coordinates are correct and all variables are as well....
4
votes
1
answer
2k
views
Converting DataFrame to GeoDataFrame with Polygon [closed]
I would like to convert my DataFrame to GeoDataFrame, but every post is about points. I need to convert polygons. Coordinates are in df['geometry']. How can I do that?
My DataFrame is below:
I was ...
3
votes
1
answer
281
views
Can't Form DataFrame from Parallel Offset Output
I've been developing code to take a .csv with lat-long coords and convert them to LineStrings before creating parallel offsets for them. This has been working so far, but yesterday after clearing my ...
2
votes
0
answers
42
views
Not able to extract values from raster TIFF in EPSG:26912, but can in EPSG:4326?
I have an elevation file (.tif) in EPSG:4326 and point data for wildfire occurrence in the same projection. When I use this projection, I can use the following code to extract the elevation value, for ...
1
vote
1
answer
302
views
Extracting polygon information from KML file into DataFrame
I have KML file from downloaded https://data.gov.sg/dataset/electoral-boundary_2020. As you can see on the website, there are 31 sub-polygons and each of them has a label. I have loaded the KML on R.
...
3
votes
1
answer
2k
views
Converting DataFrame with geometry column into GeoDataFrame in Pandas
I have this DataFrame:
In [120]: a
Out[120]:
a b c
0 111 333 [POINT (0 0)]
1 222 444 [POINT (0 0)]
I am trying to convert with the next line, but it fails:
In [125]: b = ...
0
votes
1
answer
58
views
Restructure data.frame By Date Values in R [closed]
I have a data.frame in R shown below..
This data.frame summarizes counts by week for every year in a time series dataset.
I am now trying to rearrange this matrix such that the years (2001-2020) will ...
-1
votes
1
answer
24
views
What will be the coordinate system of base map layers added if the the coordinate of layer frame properties is MUTM in ArcGIS?
My coordinate frame is in MUTM that I have created. I have added base map layer and I want to know what coordinate system will it use.
1
vote
0
answers
106
views
Export to PNG produces wrong color background (but not for JPG)
I need to export a map as a PNG image, but when I do the background, which is supposed to be white, comes out gray. This also happens when I export it as a TIFF or EMF, but not as a JPG.
I have tried ...
0
votes
1
answer
367
views
Convert multiband GeoTIFF to dataframe using all bands (R, Python or QGIS) [closed]
I have a GeoTIFF file with 2 bands and I want to create a dataframe like this:
pixelID | band1Value | band2Value
I would like to do it in R, Python or QGIS.
As far as what I have searched, I could ...
2
votes
1
answer
1k
views
GeoPandas gdf.geometry.buffer for spatial join
In that part of the code I'm creating geodataframes (only point features) out of two CSV files. I want to merge all points from the two dataframes within a range of 150m. Therefore I create a buffer ...
1
vote
0
answers
217
views
List of sf-object into one sf-object
that's a really simple question but I am kind of stuck with it. I have a list with multiple sf-objects and I want to put all sf-objects (dataframe) under each other and build one final sf-object. How ...
2
votes
1
answer
72
views
Apply different symbology layers to different dataframes with arcpy mapping?
I have one shapefile, which I want to create a map of with 3 different data frames (showing three different attributes of the shapefile) on one map. I have 3 separate symbology layers files saved to ...
1
vote
1
answer
452
views
How to import raster from PostGIS into Python as dataframe
I am trying to import the raster from PostGIS into a raster for further analysis. I know that I should use psycopg2 to connect to DB, but I do not know how to query the raster from DB, and then ...
2
votes
1
answer
467
views
Add a timestamp to a dataframe in Python/Earth Engine
I came across an example kindly shared on youtube by Madhu Mysore. Here is the link: https://www.youtube.com/watch?v=IGUYSeoeHhg&t=2105s.
I changed the code as I am not interested in regions at ...
1
vote
1
answer
406
views
Removing labels from inset areas within main data frame
I have three inset maps (separate data frames) within my map. I want to not label the buildings within the inset map extent on the main data frame, but keep labels outside of the inset extent. If it ...
3
votes
1
answer
794
views
ArcPy - List layers and list fields in one code
I am trying to combine ListDataframes, ListLayers and ListFields in one ArcPy code.
I can do it one by one (first list layers in one code, and then list fields in second code), but I am trying to do ...
1
vote
1
answer
25
views
How to determine column value based on lowest value from other column? [closed]
I have the following dataframe with same value in 'nearest_beacon' column but different distance in 'vms_distance' column.
My Dataframe:
nearest_beacon vms_distance associated
4548780 0.486456 ...
0
votes
1
answer
46
views
Dataframe data handling or SQL Query in ArcMap
I'm trying to perform an SQL query in ArcMap with the following data set, and I have not been able to solve the problem.
The idea is to keep all the information of the columns, but for example if the ...
8
votes
2
answers
1k
views
Read N number of rows from shapefile using GeoPandas
Pandas has a parameter nrows for selecting how many rows will be read into the DataFrame.
Does GeoPandas have a similar parameter? Couldn't find in the documentation.
2
votes
1
answer
319
views
Placing data frame as inset on only one page of Data Driven Pages map book?
I am using data driven pages to make a 5-page mapbook of an area. There is also one far-away site that I wanted to include an inset of on the first page of my mapbook (near to where it is). However, I ...
2
votes
0
answers
275
views
Rotating symbols by Data Frame coordinate system in ArcGIS Pro?
Is it possible to ensure that symbols rotated by attribute (compass azimuth) retain their proper orientation when the Data Frame coordinate system changes?
Answers have been provided for this issue ...
6
votes
2
answers
5k
views
Convert SpatialPoints to SpatialPointsDataFrame
Give an object x of class SpatialPoints how do I convert it to a SpatialPointsDataFrame ?
class : SpatialPoints
features : 50
extent : 3187836, 3827836, -489229.3, 950770.7 (xmin, ...
1
vote
4
answers
3k
views
QGIS Data Frame Clipping for Basemaps
In ARCGis its possible to Clip your Data Frame so you just see the Data within the defined area. Like shown here:
https://www.cdc.gov/dhdsp/maps/pdfs/GIS-Tips-Data-Frame-Clip-Function.pdf
With this ...
0
votes
0
answers
140
views
Switching Between GCS & PCS in a Data Frame For Accurate Acreage/Distance Measurements
I'm working with a data frame that contains multiple layers; data frame and layers all use a GCS (WGS_1984). On one layer in particular, I want to be able to draw and measure the acreage of polygons. ...