Analysis of international trade often requires complex statistical models that account for differences between exporters, importers and their partners. The more detailed the comparison, the more data and computing resources are needed. On an ordinary computer such calculations may simply fail to run because of insufficient RAM.
A free program called Capybara 2.0, developed at the University of Surrey (UK), proposes to solve this problem. Its author, Mauricio Vargas Sepulveda, a doctoral student in economics, described the results in a preprint - a scientific paper published before peer review - on the SSRN server. The program does not build huge tables of additional variables, as traditional methods do, but uses a different way of accounting for differences that saves memory.
In the tests, Capybara was compared with the base R environment (a programming language for statistics) and two specialized packages - Fixest and Alpaca. The tests were repeated 100 times on a standard Lenovo laptop. The largest data set contained 6,006 observations for 1994-2006.
On this data set, Capybara 2.0 required less than 1 megabyte of memory. For comparison: the base R approach took about 897 megabytes, Fixest about 6 megabytes, and Alpaca about 54 megabytes. These figures relate to the specific model tested, not to all possible applications. In terms of speed, Capybara remained competitive.
In addition, the new version identifies cases where the model cannot produce correct finite estimates and helps avoid distorted results. Another feature allows patterns at the lower and upper edges of trade flows to be studied, not just average values.
"If a model needs more memory than the computer has, waiting will not help - it simply cannot be run. Lowering the requirements can be the difference between answering an economic question and giving up on it," Vargas Sepulveda explained.
According to him, access to complex economic analysis should not depend on expensive software or powerful hardware. The free package helps remove practical barriers, especially for researchers with limited resources.
The program, documentation and code for reproducing the analysis are freely available. This allows other specialists to check the methods and apply them to their own data. However, for now this is a preprint and a laboratory development, not a commercial product with guaranteed support.