$fields = array(
'name' => 'chunk2015',
'snippet' => 'snippetName'
);
$chunk = $modx->newObject('modChunk');
$chunk->fromArray($fields);
This question has been answered by wshawn. See the first response.
$chunk->setContent('Some Content');
$content = $chunk->getContent();
$content = $modx->getChunk('ChunkName');<p>Placeholder one: [[+placeholder1]]</p> <p>Placeholder two: [[+placeholder2]]</p>
$myPlaceholders = array (
'placeholder1' => 'value1',
'placeholder2' => 'value2',
// etc.
);
$content = $modx->getChunk('ChunkName', $myPlaceholders);