JosiahParry / sfdep

A tidy interface for spatial dependence
https://sfdep.josiahparry.com/
GNU General Public License v3.0
121 stars 5 forks source link

Create CLQ #8

Closed JosiahParry closed 2 years ago

JosiahParry commented 2 years ago

xtabs / length xij

JosiahParry commented 2 years ago

Current dev is slow and computationally expensive. Try using it with data.table for speed and memory improvements

JosiahParry commented 2 years ago

Data table was just as fast and slightly more computationally intensive. I think the current approach is slightly wrong and the data table one is more correct

JosiahParry commented 2 years ago

It actually seems that the calculation is rather quick, but rather the permutations that take a long time median 152ms with lapply implementation and 550kb mem alloc. 157ms 900kb using data.table.

The permutation is what takes the longest allocation a lot more memory and time. Should take ~275mb of memory. It was taking far more than that ~700mb.

~Additionally, I think the calculation is slightly wrong. Must revise~ Edit: was just working on two separate samples lol

JosiahParry commented 2 years ago

Development almost complete at https://github.com/JosiahParry/sfdep/tree/clcq

Only need to complete documentation.

Each function should have:

JosiahParry commented 2 years ago

closed in https://github.com/JosiahParry/sfdep/pull/11