  We study the influence of the large-scale interplanetary magnetic field
configuration on the solar energetic particles (SEPs) as detected at different
satellites near Earth and on the correlation of their peak intensities with the
parent solar activity. We selected SEP events associated with X and M-class
flares at western longitudes, in order to ensure good magnetic connection to
Earth. These events were classified into two categories according to the global
interplanetary magnetic field (IMF) configuration present during the SEP
propagation to 1AU: standard solar wind or interplanetary coronal mass
ejections (ICMEs). Our analysis shows that around 20% of all particle events
are detected when the spacecraft is immersed in an ICME. The correlation of the
peak particle intensity with the projected speed of the SEP-associated coronal
mass ejection is similar in the two IMF categories of proton and electron
events, $\approx 0.6$. The SEP events within ICMEs show stronger correlation
between the peak proton intensity and the soft X-ray flux of the associated
solar flare, with correlation coefficient $r=\,$0.67$\pm$0.13, compared to the
SEP events propagating in the standard solar wind, $r=\,$0.36$\pm$0.13. The
difference is more pronounced for near-relativistic electrons. The main reason
for the different correlation behavior seems to be the larger spread of the
flare longitude in the SEP sample detected in the solar wind as compared to SEP
events within ICMEs. We discuss to which extent observational bias, different
physical processes (particle injection, transport, etc.), and the IMF
configuration can influence the relationship between SEPs and coronal activity.
