@@ -582,17 +582,39 @@ def with_pvwatts(cls, system, location,
582
582
constructor and take precedence over the default
583
583
configuration.
584
584
585
+ Warning
586
+ -------
587
+ The PVWatts model defaults to 14 % total system losses. The PVWatts
588
+ losses are fractions of DC power and can be modified, as shown in the
589
+ example below.
590
+
585
591
Examples
586
592
--------
593
+ >>> from pvlib import temperature, pvsystem, location, modelchain
587
594
>>> module_parameters = dict(gamma_pdc=-0.003, pdc0=4500)
588
595
>>> inverter_parameters = dict(pdc0=4000)
589
- >>> tparams = TEMPERATURE_MODEL_PARAMETERS['sapm']['open_rack_glass_glass']
590
- >>> system = PVSystem(surface_tilt=30, surface_azimuth=180,
591
- ... module_parameters=module_parameters,
592
- ... inverter_parameters=inverter_parameters,
593
- ... temperature_model_parameters=tparams)
594
- >>> location = Location(32.2, -110.9)
595
- >>> ModelChain.with_pvwatts(system, location)
596
+ >>> tparams = temperature.TEMPERATURE_MODEL_PARAMETERS['sapm']['open_rack_glass_glass']
597
+ >>> system = pvsystem.PVSystem(
598
+ >>> surface_tilt=30, surface_azimuth=180,
599
+ >>> module_parameters=module_parameters,
600
+ >>> inverter_parameters=inverter_parameters,
601
+ >>> temperature_model_parameters=tparams)
602
+ >>> loc = location.Location(32.2, -110.9)
603
+ >>> modelchain.ModelChain.with_pvwatts(system, loc)
604
+
605
+ The following example is a modification of the example above but where
606
+ custom losses have been specified.
607
+
608
+ >>> pvwatts_losses = {'soiling': 2, 'shading': 3, 'snow': 0, 'mismatch': 2,
609
+ >>> 'wiring': 2, 'connections': 0.5, 'lid': 1.5,
610
+ >>> 'nameplate_rating': 1, 'age': 0, 'availability': 30}
611
+ >>> system_with_custom_losses = pvsystem.PVSystem(
612
+ >>> surface_tilt=30, surface_azimuth=180,
613
+ >>> module_parameters=module_parameters,
614
+ >>> inverter_parameters=inverter_parameters,
615
+ >>> temperature_model_parameters=tparams,
616
+ >>> losses_parameters=pvwatts_losses)
617
+ >>> modelchain.ModelChain.with_pvwatts(system_with_custom_losses, loc)
596
618
ModelChain:
597
619
name: None
598
620
clearsky_model: ineichen
0 commit comments