Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Standard Deviation function is not working #78

Open
SivaramKanagaraj opened this issue Aug 23, 2019 · 2 comments
Open

Standard Deviation function is not working #78

SivaramKanagaraj opened this issue Aug 23, 2019 · 2 comments

Comments

@SivaramKanagaraj
Copy link

SivaramKanagaraj commented Aug 23, 2019

I trying to get standard deviation of a variable, but i getting below error.

PandaSQLException: (sqlite3.OperationalError) no such function: STDEV

@stonebig
Copy link
Contributor

STDEV is not in standard SQLite.

It's available in a C extension of SQLite "extension-functions.c" described here https://www.sqlite.org/contrib?orderby=date

The possible workaround is you to inject the needed function in Python in SQLite database.

It would do something like that, in a nasty proof of concept.

image

@raprice3
Copy link

I have used the extension-functions.c SQLite extension (https://www.sqlite.org/contrib/download/extension-functions.c) mentioned above in the SQLite command line and in SQLite studio, it isn't very hard to do. The R package RSQLite includes these extension functions already (see https://cran.r-project.org/web/packages/sqldf/README.html), which makes using SQLite in R very useful.

This is a feature request -- is it possible to get those extension functions loaded automatically? It would be tremendously helpful.

Thanks,

Richard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants