Hello everyone, welcome to another ArcGIS Pro tutorial. In this article, we will learn a simple but useful trick to convert a string (text) to float (number) using Calculate field. In my case, I have a point layer with an elevation field/column in the attribute table. But unfortunately, the elevation values are not stored in number format. This will create an issue because I want to use the elevation values to produce Digital Elevation Model from the survey data points. Calculate Field is a powerful tool in ArcGIS Pro to manipulate the data attribute.
![](https://freegistutorial.com/wp-content/uploads/2022/01/2022-01-18_10-22-32-1024x697.png)
![](https://freegistutorial.com/wp-content/uploads/2022/01/2022-01-18_10-23-47-968x1024.png)
As you can see above, we will convert the field “hyoukouchi” from text to number. We will create a new field “elevation” to store the new values.
![](https://freegistutorial.com/wp-content/uploads/2022/01/2022-01-18_10-41-44.png)
Open the Attribute Table and then click Calculate Field. The Calculate Field window will open up and we need to specify some variables here.
- Input table: Select the table you want to modify
- Field name: Elevation
- Expression Type: Python3
Elevation = float(!hyoukouchi!)
Don’t forget the “!” symbols
![](https://freegistutorial.com/wp-content/uploads/2022/01/2022-01-18_10-44-46-1024x663.png)
Click Apply or OK to start the process.
So now, we have a new Elevation field that contains the same data as the hyoukouchi field but this time the data is stored as number/float.
![](https://freegistutorial.com/wp-content/uploads/2022/01/2022-01-18_10-48-59-1024x487.png)