Possible Function categorization

Hi ,

As i see the function definition in opengamma is quite generic and there are instances where one might thing there should exist categories in function and they should be handled differently.

By generic i mean that any object can go as input to the function and any object can come as output to the function.
The instance where i gave this thought is as follows.

Some of the function works on N number of inputs and outputs a single value. Here if we want a report over a date range , we can just create a historicalmarketdataspecefication for each date and run it as a Batch process. A function that finds square root of a timeseries is one such example.

Some other functions works on a list of values (like timeseries) and outputs a single value. Here if we want a report over a date range , we somehow passes the from and to dates to the function and run it in a single cycle. A function that finds the largest number in a timeseries is an example.

The issue i see , comes when a aggregate of both these types of function are used in a single ViewDefenition.
The second type of function would be executed unnecessary for N times and special care have to be taken to aggregate them with the former kind of functions.

How can such situations tackled in opengamma platform ?

Thanks
Vineeth

Is there anymore details that i should provide for this question. If so , please let me know.

Thanks
Vineeth

I’m not entirely clear what you’re asking. You seem to be saying that in some cases you want to operate over a whole time series and in some cases a single point. If you operate over a whole series and don’t change any of the inputs, then by default that calculation will only be done on the first cycle, it would only be recomputed each time if you’re using a different view definition or if you set the execution options to force recalcs.