Hi. Just wondering if anyone could tell me what's wrong with the temp_layer here? I am using the temp layer to avoid problems with the PointToRaster_conversion and data sources with joins. (error 000055)
import arcpy
from arcpy.sa import *
arcpy.env.workspace = r"C:\Users\aazma\Desktop\Incomplete(503)\Incomplete"
arcpy.env.overwriteOutput = True
in_csv = r"C:\Users\aazma\Desktop\Incomplete(503)\Incomplete\PCBsData.csv"
out_raster = r"C:\Users\aazma\Desktop\Incomplete(503)\Incomplete\output.tif"
layer_name = "temp_layer"
x_field = "X"
y_field = "Y"
spatial_reference = arcpy.SpatialReference(4326)
arcpy.MakeXYEventLayer_management(in_csv, x_field, y_field, layer_name, spatial_reference)
cellsize = 0.1
value_field = "value"
assignment_type = "MEAN"
arcpy.PointToRaster_conversion(layer_name, value_field, out_raster, assignment_type, value_field, cellsize)
arcpy.Delete_management(layer_name)