I am working with MOD17A3 time series for trend analysis. Not sure I suppose to exclude Fillvalue since I am focusing on vegetation. For example 32762 = land cover assigned as urban/built-up
As a matter of principle, if you wish to characterize the presence of a trend in a time series of vegetation Net Primary Productivity, you should exclude any and all data points that are not explicitly representative of vegetation from that time series, such as data characterizing water bodies, buildings or clouds, for instance.
This being said, the way you cast your question is somewhat ambiguous and potentially problematic, because a time series is presumably constructed for a particular location: in your case for a vegetated patch. If indeed your target is vegetated, it should not include data points identified as 'urban/built-up'. Conversely, if your time series does include such data points, then it certainly does not represent the evolution of a vegetated area (in the sense of agriculture, or forest, or a protected area).
Are you looking at an area that used to be vegetated and was subsequently built-up? In that case, limit your analysis to the period where the area is vegetated. Or are you looking at a large area that includes multiple land cover types? Then simplify your problem by isolating a smaller area that only contains vegetation.
You should perhaps sharpen your request or explain in more detail how you end-up having urban data in a vegetation time series.
Thank you Michel for the details. Those are fill values in MOD17A3HGF Net Primary Productivity. My focus to detect the trend of Net Primary Productivity for 20 years using raster time series analysis in R
ValueDescription
32761Land cover assigned as "unclassified" or not able to determine
32762 Land cover assigned as urban/built-up
32763Land cover assigned as "permanent" wetlands/inundated marshland
32764Land cover assigned as perennial snow, ice
32765Land cover assigned as barren, sparse veg (rock, tundra, desert)
32766Land cover assigned as perennial salt or inland fresh water