I am trying to export multiple gdf to shp and name these shp by the gdf name. I have found this solution
here is my list:
maloobchod_list = [maloobchod2006_geom, maloobchod2011_geom, maloobchod2015_geom, maloobchod2016_geom]
and here is the code:
folderpath=r"E:\folder"
shp = shp
for maloobchod, gdf in enumerate(maloobchod_list, 1):
filename="gdf_{}.{}".format(maloobchod, shp)
filepath=os.path.join(folderpath, filename)
gdf.to_file(filepath, encoding='utf-8')
It looks like it saves all the shp from the list, but the names are not the same as the actual gdf from the list.