Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default Which sorting technique does Excel use in the sort function?

Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,726
Default Which sorting technique does Excel use in the sort function?

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default Which sorting technique does Excel use in the sort function?

I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?




  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 6,582
Default Which sorting technique does Excel use in the sort function?

It's still irrelevant. What, did the teacher read something in PC World?

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
http://PeltierTech.com
_______


"DNALESOR" wrote in message
...
I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my
addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?






  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,365
Default Which sorting technique does Excel use in the sort function?

I don't know either, and I tend to agree with Jon Peltier on this one: it's
irrelevant. It may have actually changed over the years without our ever
knowing that it did. That's the beauty of 'black-box' construction: you do
not need to know how a thing works inside, only that it does work, and what
information you need to provide to it and what to expect from it.

I rather doubt that it is a bubble sort, though.

"DNALESOR" wrote:

I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11
Default Which sorting technique does Excel use in the sort function?

I used to work with an engineer who was notorious for trying out things he
read in some magazine. He screwed up more projects that way than you can
imagine.


--
JoAnn Paules
MVP Microsoft [Publisher]

~~~~~
How to ask a question
http://support.microsoft.com/KB/555375


"Jon Peltier" wrote in message
...
It's still irrelevant. What, did the teacher read something in PC World?

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Tutorials and Custom Solutions
http://PeltierTech.com
_______


"DNALESOR" wrote in message
...
I need to find out for my programming class and I haven't been able to
find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my
addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?







  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default Which sorting technique does Excel use in the sort function?

Yes, it may be irrelevant, but he just wants to know if we can figure it out
and I'm just trying to find the answer. But thanks for possibly knocking out
the bubble sort option.


"JLatham" wrote:

I don't know either, and I tend to agree with Jon Peltier on this one: it's
irrelevant. It may have actually changed over the years without our ever
knowing that it did. That's the beauty of 'black-box' construction: you do
not need to know how a thing works inside, only that it does work, and what
information you need to provide to it and what to expect from it.

I rather doubt that it is a bubble sort, though.

"DNALESOR" wrote:

I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,365
Default Which sorting technique does Excel use in the sort function?

You're not the first to ask the question (or to get it from the same source:
a class)
http://groups.google.com/group/micro...b95ec18b1007a2

Some other possible leads or at least interesting related reading (if you
consider reading about test results of various sort algorithms interesting)
http://www.standards.com/Sorting/Sor...scription.html
http://www.mvps.org/dmcritchie/excel/sorting.htm

So, young grasshopper, the question remains unanswered, a secret of the
universe to yet be discovered... wax on.... wax off....

If I had to GUESS, I'd put my bet on a variation of either a QuickSort or
Heap Sort. I base that guess on the ability of Excel's sort to give various
errors (as out of stack space and/or out of memory). You would not get that
behavior from a simple (and extremely inefficient) bubble sort unless the
amount of data was simply overwhelming. I don't think you'd get the
performance you see out of a bubble sort either - not for large numbers.

Now - did anyone think there might be two or more algorithms inside of the
Sort option? It's possible, since in some cases a bubble sort, for example,
can be more efficient than one of the others when used on a small number of
items to be sorted? Imagine a routine that determines the number of items to
be sorted and simply says, in effect, if # to sort is less than X, use
bubble, else use something fancier?

But regardless, the algorithm is customized to some degree - empty cells
always ending up at the bottom of the list rather than at the top (surely
emptiness is less than not-emptiness?). I believe there's a great
opportunity for a book: Zen and the Sort, or All Sorts of Zen, here somewhere.

"DNALESOR" wrote:

Yes, it may be irrelevant, but he just wants to know if we can figure it out
and I'm just trying to find the answer. But thanks for possibly knocking out
the bubble sort option.


"JLatham" wrote:

I don't know either, and I tend to agree with Jon Peltier on this one: it's
irrelevant. It may have actually changed over the years without our ever
knowing that it did. That's the beauty of 'black-box' construction: you do
not need to know how a thing works inside, only that it does work, and what
information you need to provide to it and what to expect from it.

I rather doubt that it is a bubble sort, though.

"DNALESOR" wrote:

I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?



  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,726
Default Which sorting technique does Excel use in the sort function?

My bet would be that there was some optimising logic in there.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"JLatham" <HelpFrom @ Jlathamsite.com.(removethis) wrote in message
...
You're not the first to ask the question (or to get it from the same
source:
a class)
http://groups.google.com/group/micro...b95ec18b1007a2

Some other possible leads or at least interesting related reading (if you
consider reading about test results of various sort algorithms
interesting)
http://www.standards.com/Sorting/Sor...scription.html
http://www.mvps.org/dmcritchie/excel/sorting.htm

So, young grasshopper, the question remains unanswered, a secret of the
universe to yet be discovered... wax on.... wax off....

If I had to GUESS, I'd put my bet on a variation of either a QuickSort or
Heap Sort. I base that guess on the ability of Excel's sort to give
various
errors (as out of stack space and/or out of memory). You would not get
that
behavior from a simple (and extremely inefficient) bubble sort unless the
amount of data was simply overwhelming. I don't think you'd get the
performance you see out of a bubble sort either - not for large numbers.

Now - did anyone think there might be two or more algorithms inside of the
Sort option? It's possible, since in some cases a bubble sort, for
example,
can be more efficient than one of the others when used on a small number
of
items to be sorted? Imagine a routine that determines the number of items
to
be sorted and simply says, in effect, if # to sort is less than X, use
bubble, else use something fancier?

But regardless, the algorithm is customized to some degree - empty cells
always ending up at the bottom of the list rather than at the top (surely
emptiness is less than not-emptiness?). I believe there's a great
opportunity for a book: Zen and the Sort, or All Sorts of Zen, here
somewhere.

"DNALESOR" wrote:

Yes, it may be irrelevant, but he just wants to know if we can figure it
out
and I'm just trying to find the answer. But thanks for possibly knocking
out
the bubble sort option.


"JLatham" wrote:

I don't know either, and I tend to agree with Jon Peltier on this one:
it's
irrelevant. It may have actually changed over the years without our
ever
knowing that it did. That's the beauty of 'black-box' construction:
you do
not need to know how a thing works inside, only that it does work, and
what
information you need to provide to it and what to expect from it.

I rather doubt that it is a bubble sort, though.

"DNALESOR" wrote:

I need to find out for my programming class and I haven't been able
to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in
my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the
sort
function of Excel? Is it bubble sort, shell sort, or interchange
sort?





  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default Which sorting technique does Excel use in the sort function?

Thank you for your help JLatham. I really appreciate you're feedback and
information.


"JLatham" wrote:

You're not the first to ask the question (or to get it from the same source:
a class)
http://groups.google.com/group/micro...b95ec18b1007a2

Some other possible leads or at least interesting related reading (if you
consider reading about test results of various sort algorithms interesting)
http://www.standards.com/Sorting/Sor...scription.html
http://www.mvps.org/dmcritchie/excel/sorting.htm

So, young grasshopper, the question remains unanswered, a secret of the
universe to yet be discovered... wax on.... wax off....

If I had to GUESS, I'd put my bet on a variation of either a QuickSort or
Heap Sort. I base that guess on the ability of Excel's sort to give various
errors (as out of stack space and/or out of memory). You would not get that
behavior from a simple (and extremely inefficient) bubble sort unless the
amount of data was simply overwhelming. I don't think you'd get the
performance you see out of a bubble sort either - not for large numbers.

Now - did anyone think there might be two or more algorithms inside of the
Sort option? It's possible, since in some cases a bubble sort, for example,
can be more efficient than one of the others when used on a small number of
items to be sorted? Imagine a routine that determines the number of items to
be sorted and simply says, in effect, if # to sort is less than X, use
bubble, else use something fancier?

But regardless, the algorithm is customized to some degree - empty cells
always ending up at the bottom of the list rather than at the top (surely
emptiness is less than not-emptiness?). I believe there's a great
opportunity for a book: Zen and the Sort, or All Sorts of Zen, here somewhere.

"DNALESOR" wrote:

Yes, it may be irrelevant, but he just wants to know if we can figure it out
and I'm just trying to find the answer. But thanks for possibly knocking out
the bubble sort option.


"JLatham" wrote:

I don't know either, and I tend to agree with Jon Peltier on this one: it's
irrelevant. It may have actually changed over the years without our ever
knowing that it did. That's the beauty of 'black-box' construction: you do
not need to know how a thing works inside, only that it does work, and what
information you need to provide to it and what to expect from it.

I rather doubt that it is a bubble sort, though.

"DNALESOR" wrote:

I need to find out for my programming class and I haven't been able to find
the information anywhere.

"Bob Phillips" wrote:

I don't know, but I have to ask, how does it make any difference?

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"DNALESOR" wrote in message
...
Does anyone happen to know which sorting technique is used in the sort
function of Excel? Is it bubble sort, shell sort, or interchange sort?



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
EXCEL SORT - How do I prevent 'frozen' rows from sorting? JHJ IN AZ Excel Discussion (Misc queries) 3 March 1st 06 12:16 AM
Creating a Custom Excel Function to Calculate Gini Coefficients [email protected] Excel Worksheet Functions 3 February 21st 06 11:15 PM
Excel sorting Howdy Excel Discussion (Misc queries) 8 September 22nd 05 03:23 AM
Excel Sort function should not sort the cell formatting! Lisa D.N.1 Excel Worksheet Functions 1 December 28th 04 09:37 PM
Data > Sort function amnesia? Dave D Excel Discussion (Misc queries) 1 November 29th 04 11:44 PM


All times are GMT +1. The time now is 05:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"