original_docstring: 
      Convert GeoDataFrame of Points to shapely LineString
      
docstring: Convert GeoDataFrame of Points to shapely LineString
docstring_tokens: Convert GeoDataFrame of Points to shapely LineString
code: def point_gdf_to_linestring(df):
      """
      Convert GeoDataFrame of Points to shapely LineString
      """
      if len(df) > 1:
          return df.groupby([True] * len(df)).geometry.apply(
              lambda x: LineString(x.tolist())).values[0]
      else:
          raise RuntimeError('Dataframe needs at least two points to make line!')
code_tokens: def point_gdf_to_linestring ( df ) : if len ( df ) > 1 : return df . groupby ( [ True ] * len ( df ) ) . geometry . apply ( lambda x : LineString ( x . tolist ( ) ) ) . values [ 0 ] else : raise RuntimeError ( 'Dataframe needs at least two points to make line!' )
short_docstring: Convert GeoDataFrame of Points to shapely LineString
short_docstring_tokens: Convert GeoDataFrame of Points to shapely LineString
comment: """
      Convert GeoDataFrame of Points to shapely LineString
      """