KarrLab/intro_to_wc_modeling

View on GitHub

Showing 93 of 135 total issues

Similar blocks of code found in 8 locations. Consider refactoring.
Open

    def dP2G_dt(self, x):
        return 1.0 * self.v_9(x) - 1.0 * self.v_10(x)
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 7 other locations - About 1 hr to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 357..358
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 360..361
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 363..364
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 369..370
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 381..382
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 384..385
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 387..388

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

    def dPYR_dt(self, x):
        return 1.0 * self.v_11(x) - 1.0 * self.v_12(x)
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 7 other locations - About 1 hr to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 357..358
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 360..361
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 363..364
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 369..370
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 378..379
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 381..382
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 384..385

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

    def dPEP_dt(self, x):
        return 1.0 * self.v_10(x) - 1.0 * self.v_11(x)
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 7 other locations - About 1 hr to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 357..358
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 360..361
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 363..364
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 369..370
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 378..379
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 381..382
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 387..388

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

    def dP3G_dt(self, x):
        return 1.0 * self.v_8(x) - 1.0 * self.v_9(x)
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 7 other locations - About 1 hr to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 357..358
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 360..361
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 363..364
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 369..370
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 378..379
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 384..385
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 387..388

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

            mean, var = stats.gamma.stats(self.k_m / self.gamma_n, scale=self.k_n / self.gamma_m)
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 369..369

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        model.reactions.append(Reaction(
            id=str(ws.cell(row=iRow, column=1).value),
            name=ws.cell(row=iRow, column=2).value,
            submodel=ws.cell(row=iRow, column=3).value,
            reversible=stoichiometry['reversible'],
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 698..713
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 765..771

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

            mean, var = stats.gamma.stats(self.k_m / self.gamma_n, scale=self.k_n / self.gamma_m)
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 366..366

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        model.references.append(Reference(
            id=str(ws.cell(row=iRow, column=1).value),
            name=ws.cell(row=iRow, column=2).value,
            crossRefs=[
                Identifier(
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 698..713
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 731..744

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 8 locations. Consider refactoring.
Open

    def dBPG_dt(self, x):
        return 1.0 * self.v_7(x) - 1.0 * self.v_8(x)
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 7 other locations - About 1 hr to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 360..361
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 363..364
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 369..370
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 378..379
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 381..382
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 384..385
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 387..388

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        model.species.append(Species(
            id=str(ws.cell(row=iRow, column=1).value),
            name=ws.cell(row=iRow, column=2).value,
            structure=ws.cell(row=iRow, column=3).value,
            empiricalFormula=ws.cell(row=iRow, column=4).value,
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 731..744
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 765..771

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 40.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 1,  98], color='r', linestyle=':', label='mRNA={}, Protein={}'.format(1,  98))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 537..537
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 539..539
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 540..540
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 541..541
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 542..542

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 0, 101], color='g', linestyle='-', label='mRNA={}, Protein={}'.format(0, 101))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 537..537
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 538..538
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 540..540
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 541..541
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 542..542

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 0, 104], color='b', linestyle='-', label='mRNA={}, Protein={}'.format(0, 104))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 537..537
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 538..538
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 539..539
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 540..540
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 542..542

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

class Concentration(object):
    # Represents a concentration in a compartment

    compartment = ''
    value = None
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 579..587

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 1, 104], color='b', linestyle=':', label='mRNA={}, Protein={}'.format(1, 104))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 537..537
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 538..538
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 539..539
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 540..540
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 541..541

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

class ExchangedSpecies(object):
    # Represents an external

    id = ''
    reactionIndex = None
intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/model.py on lines 548..556

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 0,  98], color='r', linestyle='-', label='mRNA={}, Protein={}'.format(0,  98))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 538..538
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 539..539
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 540..540
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 541..541
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 542..542

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 6 locations. Consider refactoring.
Open

        axes.semilogy(t, p[:, 1, 101], color='g', linestyle=':', label='mRNA={}, Protein={}'.format(1, 101))
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 537..537
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 538..538
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 539..539
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 541..541
intro_to_wc_modeling/cell_modeling/simulation/mrna_and_proteins_using_several_methods.py on lines 542..542

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 39.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        return (self.VmGLT*(self.GLCo - x[5]/self.KeqGLT))/(self.KmGLTGLCo*(1 + self.GLCo/self.KmGLTGLCo + x[5]/self.KmGLTGLCi + (0.91*self.GLCo*x[5])/(self.KmGLTGLCi*self.KmGLTGLCo)))
Severity: Major
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 2 other locations - About 55 mins to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 292..292
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 542..543

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 37.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        return (-((self.VmGAPDHr*x[1]*x[7])/(self.KmGAPDHBPG*self.KmGAPDHNADH)) + (self.KeqTPI*self.VmGAPDHf*x[6]*x[13])/((1 + self.KeqTPI)*self.KmGAPDHGAP*self.KmGAPDHNAD))/((1 + x[6]/self.KmGAPDHNAD + x[7]/self.KmGAPDHNADH)*(1 + x[1]/self.KmGAPDHBPG + (self.KeqTPI*x[13])/((1 + self.KeqTPI)*self.KmGAPDHGAP)))
Severity: Minor
Found in intro_to_wc_modeling/cell_modeling/model_composition.py and 1 other location - About 55 mins to fix
intro_to_wc_modeling/cell_modeling/model_composition.py on lines 297..297

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 37.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language