Q:

Find Array keys with similar names and rename it

I'm looking for a function that finds array keys with similar names and rename it.
Example:
Array('Joes house' => 'some text', 'Joe`s House' => 'more Text', 'Bob' => 'text...')

Result:
Array('New Key' => 'some text', 'New Key' => 'more Text', 'Bob' => 'text...')

I think about a mixture of this functions:
array_keys($array)
similar_text($word1' $word2)

In a foreach Loop.
Any ideas?
Thanks a lot!
EDIT :
In the first post i forgot that there is a sub-array inside my array...
I've built my function now. Is this a good way to do this job or is there a more efficient way?
$array = array('Joe\'s House' => array('ABB', 'CDE'), 'Joes Pizza' => 'GDU', 'Jims House' => 'RDS', 'Joe Horse' => 'ABB', 'Joes Housee' => 'HCT');

echo "<pre>Original ";
print_r($array);
echo "</pre>";

$keys = array_keys($array);
$first = null;
$filter = array();
$add = array();

foreach($keys as $key) {
    foreach($keys as $check) {
        similar_text($key, $check, $percent);
        if($percent > 90 && $key != $check) {
            //Buffer first similar array key
            if(empty($first)) {
                $first = $key;
            }
            // build filter array
            $filter[$check] = $array[$check];
            // build add array
            if(is_array($array[$check])) {
                $add[$first] = array_merge($add[$first], $array[$check]);
            }
            else {
                $add[$first][] = $array[$check];
            }
        }
    }
}

$array = array_diff($array, $filter);
$result = array_merge($array, $add);

echo "<pre>To delete ";
print_r($filter);
echo "<pre>To add ";
print_r($add);
echo "Final filtered ";
print_r($result);
echo "</pre>";

Output looks like this:

Original Array
(
    [Joe's House] => Array
        (
            [0] => ABB
            [1] => CDE
        )

    [Joes Pizza] => GDU
    [Jims House] => RDS
    [Joe Horse] => ABB
    [Joes Housee] => HCT
)

To delete Array
(
    [Joes Housee] => HCT
    [Joe's House] => Array
        (
            [0] => ABB
            [1] => CDE
        )

)

To add Array
(
    [Joe's House] => Array
        (
            [0] => HCT
            [1] => ABB
            [2] => CDE
        )

)

Final filtered Array
(
    [Joes Pizza] => GDU
    [Jims House] => RDS
    [Joe Horse] => ABB
    [Joe's House] => Array
        (
            [0] => HCT
            [1] => ABB
            [2] => CDE
        )

)

A:

Maybe something like:
$array = array('Joes house' => 'some text', 'Joe`s House' => 'more Text');
$keys = array_keys($array);
foreach($keys as $key) {
    $key_size = strlen($key);
    foreach($keys as $check) {
        if(((similar_text($key, $check) / $key_size) * 100) > 80 && $key != $check) {
            echo '80% MATCH!';
            //Create new array item
            $array['new_key'] = $array[$check];
            //Delete old array item
            unset($array[$check]);
        }
    }
}

