return data as array