Changes between Version 6 and Version 7 of Orange25/DevelopmentGuidelines


Ignore:
Timestamp:
02/04/12 12:57:55 (2 years ago)
Author:
marko
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Orange25/DevelopmentGuidelines

    v6 v7  
    1 == CamelCase to underscore_separated == 
     1== Documentation == 
     2 
     3=== Code samples === 
     4 
     5Each code sample should be a python script and should only be (perhaps partially) referenced in the file. Never copy the code into the documentation. This also holds for most of the one-liners, as code in separate files is much easier to test and fix when interface changes. 
     6 
     7Import just '''Orange''' and use full paths. Avoid exceptions. Never import *. 
     8 
     9== Coding == 
     10 
     11=== CamelCase to underscore_separated === 
    212 
    313Names of methods, functions, (object) attributes and keyword attributes of functions should all be underscore_separated. Abbreviations should also be in lower case. For example, we should rename AUCWilcoxon to auc_wilcoxon (and not AUC_wilcoxon). 
     
    515For now, all C++ code is accessible both with CamelCase and underscore separated [wiki:Orange25/C++CamelCase (detailed description)]. Python code should be converted with [wiki:Orange25/NameDeprecationDecorators name deprecation decorators] (see the page for an example). 
    616 
    7 == Refactoring tool == 
     17=== Refactoring tool === 
    818 
    919Do forget to update the [wiki:Orange25/RefactoringTool refactoring rules]. 
    1020 
    11 == Output of models == 
     21=== Output of models === 
    1222 
    1323Output of learning models. Learning models (classifiers, regressors) need to have `__str__` defined. If it needs a parameter, also add a `to_string` method, but `__str__` should still return something. For example 
     
    1929}}} 
    2030 
    21 == Model plotting == 
     31=== Model plotting === 
    2232 
    2333The most typical one should be `plot()`, but if there are multiple different plots, prefix them with `plot_`, for example `plot_dendrogram`. 
    2434 
    25 TODO: what should be default output? 
    26  
    27 == Data set naming == 
     35=== Data set naming === 
    2836 
    2937In documentation, do not use '''table'''. Name of the data set is preferred (but just '''data''' is also acceptable), so write: 
     
    3240}}}  
    3341 
    34 In code, use '''data'''. 
    35  
    36 == Documentation imports == 
    37  
    38 Import just '''Orange''' and use full paths. Avoid exceptions. Never import *. 
     42In code, use `data`.