> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wherobots.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ST_PolygonFromText (Python)

> Generate a polygon from a list of coordinates separated by a delimiter stored in a string column.

Generate a polygon from a list of coordinates separated by a delimiter stored
in a string column.

SQL reference: [`ST_PolygonFromText`](/reference/wherobots-db/geometry-data/constructors/ST_PolygonFromText)

## Signature

```python theme={"system"}
from sedona.spark.sql.st_constructors import ST_PolygonFromText

ST_PolygonFromText(coords: ColumnOrName, delimiter: ColumnOrName) -> Column
```

## Parameters

<ParamField path="coords" type="ColumnOrName" required>
  String column containing the coordinates.
</ParamField>

<ParamField path="delimiter" type="ColumnOrName" required>
  Delimiter separating the coordinates, a string constant must be wrapped as a string literal (using pyspark.sql.functions.lit).
</ParamField>

## Returns

<ResponseField name="return" type="Column">
  Polygon geometry column generated from the list of coordinates.
</ResponseField>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.