Quote:
Originally Posted by mburke05
i just started a new job w/ a comm. real estate firm in financial analysis.
the big first project i'm working on is kind of a mega-unwieldy model that the guy before me made that is super unorganized, hard to run, and unbelievably inefficient.
i'm experienced with messing with inputs in models and getting the correct #s and assumptions, but i'm not as familiar with the programming language behind excel (more advanced vlookup commands than simple arrays, and only really basic macros/the most simplistic of vba).
i'm being tasked to spend my first 3-4 months before our analytical work for our client (a bank) to remake this model, in a more efficient manner.
i'm honestly a little overwhelmed, and while i'm confident i can figure it out i have no idea where to begin. can anybody offer any advice? feel free to ask questions, and i'll divulge as much as i can without breaching my NDA.
i think i could pickup more efficient programming with time and diligence, which it sounds like this will require. just not sure where to start. everything right now is excel derived, taken from inputs we get from a commercial real estate accounting software yardi.
You have a system you don't understand. The thought crosses your mind maybe you could build something better starting from scratch.
My rule: You must understand the existing system completely before trying to replace it.
The reason... you don't know how much of the existing complexity is the original author not understanding the problem domain, not understanding the programming design, poor construction, bit rot, etc. You don't know how well you understand the problem domain, you not understanding programming design, you not constructing well, etc.
You have something that 'works' in some fashion. A working system is a real asset. When you make changes on a working system, you can test to see if it still works. When you don't have a working system, you're flying blind and have a horrible integration problem at the end when you try to turn it on. (See the many books on test driven development for one solution to the integration problem -- building tools as you go so you know everything you write works.)
Once you've done the work to understand the existing system inside & out, then you can replace it if you still want to.
---
VBA is a powerful language. It has types, auto complete (ctrl + space), a useful debugger, it can make & use COM libraries and windows APIs. Most of your likely coding requirements can be efficiently met entirely within VBA. If you really need multi-threading of your own code, it's not a good tool for that.
COM is powerful stuff though. It's easy to manipulate excel using COM from other Windows languages. So if some other tool (say C#) makes sense, you don't have to throw away excel.
---
Questions you need to answer:
1. Where does your input come from? Is it typed, clicked, pulled from files, pulled from web, pasted?
2. How many different questions are you trying to answer? Is there flexibility in the questions? The more general and unknown the questions, the better to stick to a tool that excel that already knows how to answer anything. You don't want to be writing your own query language.
3. What format output is useful for your users? What do they expect?
It's not clear from your question what sort of problem it is. You want to minimize the scope to some natural boundaries. As features increase, complexity goes N^2. Solve their problem, not every problem.
---
References:
If there's lots of code, this book describes how to tame it:
http://www.amazon.com/Working-Effect.../dp/0131177052
VBA in a nutshell has a brief description of the language and all the keywords. Better signal/noise than googling everything:
http://www.amazon.com/VBA-Nutshell-L...4&keywords=vba
There are many vba in excel books. I've never used one, so you are on your own there.
---
I think you should live in Excel & VBA. Focus on figuring out exactly what problems you are trying to solve. The solution to performance problems is design, not tools.
Last edited by Chips Ahoy; 09-05-2012 at 02:09 PM.