(data: any = [], options: BaseDataOptionType = {})
| 50 | export default class Series extends NDframe implements SeriesInterface { |
| 51 | |
| 52 | constructor(data: any = [], options: BaseDataOptionType = {}) { |
| 53 | const { index, columns, dtypes, config } = options; |
| 54 | if (Array.isArray(data[0]) || utils.isObject(data[0])) { |
| 55 | data = utils.convert2DArrayToSeriesArray(data); |
| 56 | super({ |
| 57 | data, |
| 58 | index, |
| 59 | columns, |
| 60 | dtypes, |
| 61 | config, |
| 62 | isSeries: true |
| 63 | }); |
| 64 | } else { |
| 65 | super({ |
| 66 | data, |
| 67 | index, |
| 68 | columns, |
| 69 | dtypes, |
| 70 | config, |
| 71 | isSeries: true |
| 72 | }); |
| 73 | } |
| 74 | } |
| 75 | |
| 76 | /** |
| 77 | * Purely integer-location based indexing for selection by position. |
nothing calls this directly
no test coverage detected