deborahmit / tastenet-mnl Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
Dear Yafei Han,
First of all, thank you for providing the replication files of your paper publicly available. I am checking your procedures to apply your model to a paper we are working on with some colleagues, and I have a question regarding how you split the data into training, development, and testing.
In this line of code, as far as I can see, you split the data at the level of choice set (or choice situations) that are available on the data and not at the level of individuals, because len(x)
corresponds to the number of choice sets in the entire sample.
Then, when you split the data, you use:
train_ind, dev_test_ind = model_selection.train_test_split(range(N), train_size = 0.7, test_size = 0.3, random_state=8)
which, I think, uses a range()
over the number of choice situations.
Hence, as far as I understand, this is not preserving the panel structure of the data since the different answers from a single individual (choice sets) can be assigned to training, development, or testing.
This seems even more problematic given that later you benchmarked your model with a Mixed Logit model in which we should account for the panel structure of the data. In particular, repeated choice situations from the same individual have special treatment as the product of Logit formulas for the entire sequences of choices of the same individual (see equations (6.2) and (6.3) of Kenneth Train's book Chapter 6)
Sadly, I couldn't find the code that replicates the Multinomial Logit (MNL) or Mixed Logit (MIXL) models reported in your article in this repository, so, unfortunately, I cannot reproduce your results.
Am I interpreting your programs correctly, or am I missing something here?
Thank you for your time :)!
Best regards,
Álvaro
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.