after-hours trading (or associate external after-hours price data with existing sids so i can trade against it)

my goal is to be able to trade after hours (till the 415 spy close, basically). but the data stops coming in at 4pm. so basically what i want to be able to do is either:

  • extend an existing sid's data (sid(SPY)) with time series data of my own so i can trade against it pre-open/post-close. i assume i would use fetch_csv for this, but i'm not sure how to make it so my stream of SPY prices would go until 415 and i would be able to use the order() function on this sid with this data.

  • the second way, which would be a hack it seems, is that there would be an order function that would enable me to trade at arbitrary levels at arbitrary times. so my new order function might look something like:

order(sid, numShares, price, datetime)  

and i could just use the price/datetime that i want to use. any thoughts? thanks