I need to loop over the contents of a column in a newly-created reactive (made by subsetting a data frame based on user input), and use it in a function.
for example:
target <- reactive({df$targetid[active$region == input$region]}) 
for (i in 1:length(target())){
target_info[[i]] <<- reactive({output <- someAPIcallingFunction(target=target(),
                                                     ma=7,
                                                     score_restrict = TRUE,
                                                     metric_restrict = "metric1")})
}
I'm not sure the square brackets are in the right place, but any help on the concept of looping over the output of a reactive would be REALLY appreciated! EDITED below for a working example.
  subset1<- reactive({
    BI_[input$brand == df$brand]
  })
  hello<- reactive({
    for (i in 1:nrow(subset1()))
      {
      print(subset1()[i,1]) }
AB
