dfp_getDeliveryForecast: getDeliveryForecast

Description Usage Arguments Value See Also Examples

Description

Gets the delivery forecast for a list of ProspectiveLineItem objects in a single delivery simulation with line items potentially contending with each other. A delivery forecast reports the number of units that will be delivered to each line item given the line item goals and contentions from other line items. Gets the delivery forecast for a list of ProspectiveLineItem objects in a single delivery simulation with line items potentially contending with each other. A delivery forecast reports the number of units that will be delivered to each line item given the line item goals and contentions from other line items. @param lineItems line items to be forecasted for delivery @param forecastOptions options controlling the forecast Gets the delivery forecast for a list of ProspectiveLineItem objects in a single delivery simulation with line items potentially contending with each other. A delivery forecast reports the number of units that will be delivered to each line item given the line item goals and contentions from other line items. @param lineItems line items to be forecasted for delivery @param forecastOptions options controlling the forecast

Usage

1
dfp_getDeliveryForecast(request_data, as_df = TRUE, verbose = FALSE)

Arguments

request_data

a list or data.frame of data elements to be formatted for a SOAP request (XML format, but passed as character string)

as_df

a boolean indicating whether to attempt to parse the result into a data.frame

verbose

a boolean indicating whether to print the service URL and POSTed XML

Value

a data.frame or list containing all the elements of a getDeliveryForecastResponse

See Also

Google Documentation for getDeliveryForecast

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
## Not run: 
filter <- "WHERE Status='DELIVERING' LIMIT 1"
one_li <- dfp_getLineItemsByStatement(list(filterStatement=list(query=filter)))[[1]]
hypothetical_line_item <- list(lineItem=
                               list(id=one_li$id,
                                    startDateTime=one_li$startDateTime,
                                    endDateTime=dfp_date_to_list(Sys.Date()+100),
                                    lineItemType=one_li$lineItemType,
                                    costType=one_li$costType, 
                                    primaryGoal=one_li$primaryGoal, 
                                    targeting=one_li$targeting))
request_data <- list(lineItems=hypothetical_line_item,
                     forecastOptions=list(ignoredLineItemIds=NULL))
dfp_getDeliveryForecast_result <- dfp_getDeliveryForecast(request_data)

## End(Not run)

StevenMMortimer/rdfp documentation built on June 11, 2019, 4:50 p.m.