ta-lib-python
ta-lib-python copied to clipboard
Implement auto data conversion
It would be convenient, if the library would handle datatype conversions behind the scenes automatically, for example, when I pass in a List as an input, but it expects a numpy array, or when it expects a list of floats, but I give it a list of ints, which it should automatically convert to floats. For now, I have implemented these conversions manually in my software, but I doubt I'm the only one who needs these conversions, so why do the devs have to keep reinventing the wheel, when the wheel could be already included with the library?
I have assumed most production use cases will have strong opinions about memory usage, data format, performance, and integration with the source of data. So working with native numpy types that are efficient when calling C code seemed the best place to start.
Can you give some examples where your prices are not floating point, or where silent data conversion is useful besides the REPL? If you provide a Python list, do you expect to get a Python list back? Should this be silent or log a warning about inefficient use of the library since it would require additional memory and overhead doing type conversion?
Can you share an example of the conversions you have implemented for your use case?
On Jul 22, 2020, at 6:46 AM, Mattias Aabmets [email protected] wrote:
It would be convenient, if the library would handle datatype conversions behind the scenes automatically, for example, when I pass in a List as an input, but it expects a numpy array, or when it expects a list of floats, but I give it a list of ints, which it should automatically convert to floats. For now, I have implemented these conversions manually in my software, but I doubt I'm the only one who needs these conversions, so why do the devs have to keep reinventing the wheel, when the wheel could be already included with the library?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.