Hi,I am using fieldimageR for pollen count but getting below mentioned error message (red colored, bold, image attached):
> library(FIELDimageR)
> library(FIELDimageR.Extra)
> library(raster)
> library(terra)
> library(mapview)
> library(sf)
> library(stars)
> # Uploading image
> EX.P<-rast("P4.jpg")
> # Reducing image resolution (fast analysis)
> EX.P<-aggregate(EX.P,fact=4)
> plotRGB(EX.P, r = 1, g = 2, b = 3)
> # Using index "BIM" to remove background (above 19)
> EX.P<-imgLAB(EX.P)
> EX.P.R1<- fieldMask(mosaic = EX.P,index = "BIM", cropValue = 19, cropAbove = T) [1] "3 layers available"
> fieldView(EX.P.R1$newMosaic) [1] "Starting analysis ..." [1] "End!"
> # Counting all pollens area>1000 (all sample)
> EX.P.Total<-fieldCount(mosaic = EX.P.R1$mask, plot=T)
Error in (function (classes, fdef, mtable) : unable to find an inherited method for function ‘width’ for signature ‘"SpatVector"’
Need help to solve this.