What would Moodle cost if developed in-house: SLOCCount: over 6M

What would Moodle cost if developed in-house: SLOCCount: over 6M

by Martín Langhoff -
Number of replies: 8
Discussing the cost of developing an LMS in-house, I did a quick run of SLOCCount on the Moodle sources (excluding lang, which more than duplicates the cost estimate).

I think the results are fairly interesting. SLOCCount isn't a very precise estimation tool (but then, I've never found a very precise one anyway). So it's imprecise and cheap/quick, rather than imprecise and expensive and time-consuming.

For large projects, however, SLOCCount is surprisingly accurate. Here are the numbers:


Totals grouped by language (some files have been misidentified):
php:        176697 (99.60%)
perl:          638 (0.36%)
sh:              40 (0.02%)
pascal:          36 (0.02%)

Total Physical Source Lines of Code (SLOC) = 177,411

Development Effort Estimate, Person-Years (Person-Months) = 45.97 (551.62) (Basic COCOMO model, Person-Months = 2.4 * (KSLOC**1.05))

Schedule Estimate, Years (Months) = 2.29 (27.53) (Basic COCOMO model, Months = 2.5 * (person-months**0.38))

Estimated Average Number of Developers (Effort/Schedule) = 20.04
Total Estimated Cost to Develop = $ 6,209,708 (average salary = $56,286/year, overhead = 2.40).

The per-directory table:

SLOC    Directory      SLOC-by-Language (Sorted)
84498  mod            php=84437,sh=40,pascal=21
59874  lib            php=59770,perl=104
5720    course          php=5720
5535    backup          php=5520,pascal=15
4681    admin          php=4681
2725    blocks          php=2725
2526    grade          php=2526
1912    auth            php=1912
1909    calendar        php=1909
1681    filter          php=1147,perl=534
1650    enrol          php=1650
1118    message        php=1118
1038    user            php=1038
712    top_dir        php=712
691    files          php=691
520    login          php=520
382    theme          php=382
100    doc            php=100
52      sso            php=52
47      rss            php=47
24      userpix        php=24
16      error          php=16
0      pix            (none)


This data was generated using David A. Wheeler's 'SLOCCount'.

Adding "lang" runs it up to 14M and over 3 years, but I don't think that's fair. Adding languages takes man-hours, but does not increase the project complexity.
Average of ratings: -
In reply to Martín Langhoff

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Martin Dougiamas -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
big grin Man, I really need to put my prices up. wink wink big grin
In reply to Martin Dougiamas

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Tony Hursh -
You should double it, at least. smile
In reply to Tony Hursh

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
I think you should put your prices up Martin, think about it you could double your price but still offer a 99% discount to close the deal smile
In reply to Martín Langhoff

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by D.I. von Briesen -
I'm curious, does this tool account for designs and changes? It seems to me that it could easily under-estimate the true effort of what it would take to design this tool if there had not been ongoing community involvement and feedback. There's simply no way that any one person or team could have come up with this solution, even with 14 million and a few years (ok, unless the team was teachers all over the world doing distance ed, I suppose).

So I'm curious how you'd factor this in.

On a related note, i've taken note that the SAKAI folks are starting to get antsy (at least some of their subscribers) and that provides a great example of how lots of money and brains and publicity does not a great product make. It seems that one or a few diligent intelligent people can often produce MUCH more efficiently than a bloated bureacracy- especially if it's a labor of love and not a business enterprise. Also, the more the one (or few) developers know the product intimately, the more efficiently they can edit/update it... whereas as the code bloats (a la microsoft) so do the teams and costs. NOBODY knows what's in vista... it wouldn't be possible as there are so many millions of lines of code.

It would be interesting to go to a reliable vendor and solicit a quote, given the specific (full) set of things that moodle does, and say, "how much to build this" - obviously it's cheaper if you already have the product and are just copying it... but even so I bet it'd be pricy.

d.i.
In reply to D.I. von Briesen

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Martín Langhoff -
> I'm curious, does this tool account for designs and changes?

It implements a very complex cost estimation model that seems to be the favourite of large consultancies. You can read more about it here: http://en.wikipedia.org/wiki/Cocomo but it includes rework, bugfixing, etc. I personally find that it is very inaccurate for small projects, but gets more and more reliable the larger the project is.

Sadly, I can only run the script after the project is done. Can't do that when I'm starting to code it ;)


In reply to Martín Langhoff

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Michael Winter -
I'm reviewing Moodle, Blackboard and Interact's suitability for delivering e-learning in the workplace, in a project with CPIT. Finding the costing data on the forum difficult to compare because it's not always clear whether people are talking in $US, $Aus or $NZ. When you estimated the development costs to be around $6.2M, was that $NZ?
In reply to Michael Winter

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by Jorge Ramirez -
We've made a similar work with Moodle 1.6.3 (plus a little experimental in-house developed block) and applied COCOMO II.
Moodle developing would need 1024 pers/month. We assumed that moodle is developed with strong reusing in mind. Now we're counting SLOC percentage of reused components, including JavaScript codes, not considered by SLOCCount.
In reply to Jorge Ramirez

Re: What would Moodle cost if developed in-house: SLOCCount: over 6M

by carlos vazquez -
It´s importante to note that COCOMOII needs to be calibrated to local data in order to produce good estimates. If you use COCOMOII with its own productivity constants you are assuming you are working on a DoD like software project. If you want to estimate using COCOMOII on an early stage you can use a 100 SLOC for each function point. To estimate the number of function points you can relate 35 FP for each data requirement mantained by the system and 15 FP for each data requirement just refereced by the system.