Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

how to roll longitude coordinate

# To adjust coordinate labels or make axis cyclic or periodic,
# you can use the Shift() and/or roll() methods as shown below:

import xarray as xr


array = xr.DataArray([1, 2, 3, 4], dims="x")

# shift the coordinate 'x' (to the right) by 2
array.shift(x=2)

# roll the coordinate 'x' (toward the right) by 2
array.roll(x=2, roll_coords=True)

Comment

PREVIOUS NEXT
Code Example
Python :: roll longitude about zero 
Python :: panda datetime ymd to dmy 
Python :: time counter in python 
Python :: numpy print options 
Python :: python join two lists as dictionary 
Python :: python auto updating clock 
Python :: tkinter app icon 
Python :: how to display a manytomany field in django rest framework 
Python :: how to install python 3.6 ubuntu 
Python :: how to find second maximum element of an array python 
Python :: python turtle shooting game 
Python :: python remove all except numbers 
Python :: __name__== __main__ in python 
Python :: connecting google colab to local runtime 
Python :: remove python2 centos 
Python :: indices of true boolean array pyton 
Python :: printing with format float to 2 decimal places python 
Python :: use of // in python 
Python :: how to import data from csv to jupyter notebook 
Python :: pickle.loads in python 
Python :: execute python in notepad++ 
Python :: mongodb group by having 
Python :: solve equation python 
Python :: what is a cube minus b cube 
Python :: python csv reader skip header 
Python :: seaborn heatmap parameters 
Python :: openpyxl xls 
Python :: check string equal with regular expression python 
Python :: how to check if all characters in string are same python 
Python :: how to make a pythoon turtle follow another? 
ADD CONTENT
Topic
Content
Source link
Name
2+5 =