Dynamic headers

Environment => Rails

I have a dynamic grid based on selected date range (Metrics, Jan, feb, March, etc)
Can I set header using instance variable which gets set in controller?

controller
def show
@trend_header = “Metrics, Jan, Feb, March”
end

view

figured out myself

mygrid.setHeader("<%= @trend_header %>");