added sma to cande_array