Home > By category > Scripts >Development Tools > VChooseK



VChooseK

  • Downloads: 
  • Views: 
  • Rating:

VChooseK(V, K) creates a matrix, which rows are all combinations of choosing K elements of the vector V without order and without repititions.

INPUT:
V: Array of class DOUBLE, SINGLE, (U)INT8/16/32/64, LOGICAL, CHAR.
K: Number of elements to choose.

OUTPUT:
Y: Matrix of size [N!/K!(N-K)!, K] with N is the number of elements of V.
Y has the same class as the input V.

The output equals Matlab's NCHOOSEK, except that NCHOOSEK replies the number of combinations for a scalar V:
VChooseK(-1, 1) replies [-1]: One element taken out of a set of length one.
NCHOOSEK(-1, 1) fails at calculating N!/K!(N-K)!.

EXAMPLES:
Choose 2 elements from [1,2,3,4]:
VChooseK(1:4, 2)
==> [1,2; 1,3; 1,4; 2,3; 2,4; 3,4]
For speed cast the input to integer types if possible:
Y = double(VChooseK(int16(1:1000), 2);
is faster than:
Y = VChooseK(1:1000, 2);
To get the combinations of cell arrays, use the combinations of the index:
C = {'a', 'b', 'c', 'd'};
C2 = C(VChooseK(1:4, 2))
==> C2 = {'a', 'b'; 'a', 'c'; 'a', 'd'; 'b', 'c'; 'b', 'd'; 'c', 'd'}

Free download from Shareware Connection - VChooseK(V, K) creates a matrix, which rows are all combinations of choosing K elements of the vector V without order and without repititions.

Publisher: Jan Simon | License: Shareware
Version: 1.0 | Size: 10 KB | Platform: Matlab, Scripts
Released Date: 17-02-2013 | Rating: 0 | Title: VChooseK

Author Url: http://www.mathworks.com
Program Info Url: http://www.mathworks.com
Download Url: http://www.mathworks.com/matlabcentral/fx_files/26190/1/VChooseK.zip

More downloads from VChooseK publisher Jan Simon:

ScaleTime - ScaleTime - fast linear matrix interpolation

DateStr2Num - DATESTR2NUM - Fast conversion of DATESTR to DATENUM

FilterM - FilterM, FiltFiltM: Fast digital filter

strncmpr - Compare last N chars of strings or cell strings

Patch FILTFILT - If applied to a matrix, the function FILTFILT (Signal Processing Toolbox) calls itself recursively for each column.

VChooseK keywords:
VChooseK related downloads:

Create Healthy Looking Error Bars - % Description errorb(x,y,varargin) errorb(Y,E) plots Y and draws an error bar at each element of Y. The error bar is a distance of E(i) above and below the curve so that each bar is symmetric and 2*E(i) long.

Temporal Potential Function based Path Planner for Dynamic Environments - A Dynamic environment is one in which either the obstacles or the goal or both are in motion.

VChooseKO - VChooseKO(V, K) creates a matrix, which rows are all permutations of choosing K elements of the vector V with order and without repetitions.

VChooseKR - VChooseKR(V, K) creates a matrix, which rows are all combinations created by choosing K elements of the vector V without order and with repetitions

VChooseKRO - VChooseKRO(V, K) creates a matrix, which rows are all permutations created by choosing K elements of the vector V with order and with repetitions.

Shareware Connection periodically updates pricing and software information of 'VChooseK' from company source 'Jan Simon' , so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft,  Using 'VChooseK' crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of VChooseK.

New Reviews

F-Secure SAFE 2014 - Not so long back, a majority of people used either desktop or laptop for web access and general computing needs. However, things have changed a lot in recent years. Nowadays, it is not uncommon to find people who use laptop, desktop and tablet ...

Apple Aperture - It is quite true that Macintosh users generally get fewer tools to pick from than Windows users but they have some solid and impressive software to work with. One such example is Apple’s professional image editing and organizing tool, ...

Magic Uneraser - Data loss can occur owing to a number of reasons, both within and beyond your control. Whether you have lost data owing to careless of another user or a hard drive failure has occurred, it is important to retrieve the data at any cost. There are ...

Diver Reviver - It is not only malware and viruses that can affect performance of your computer. Malfunctioning and outdated drivers for hardware components can also affect speed and performance of a PC perceptibly. While seasoned users take the pain of ...

Protector Plus 2014 (32-bit) - Without using suitable security software in PC, you cannot have peace of mind nowadays. Increasing instances of malware attacks and attacking exploits have prompted average PC users to resort to using antivirus and security suites for both home ...

Video Editor - With advancements in both computer software and hardware, average users are getting into activities that were hitherto reserved for professionals. There are several video editing tools aimed at casual users as well. While professional users ...

Cryper - Nowadays PC users can no longer rely completely on any security software. Newer ways of data theft and exploits are emerging on the horizon, making PC security a complicated and worrisome thing. If you are particular about the data you store in ...

TrustPort Tools - Nowadays, PC users need to deal with several types of third party apps to ensure security and privacy of data. From encrypting files to getting rid of sensitive data, the needs can be numerous. There are many such tools that can be used in this ...

ProAnimator - In Post production setups and 3D animation studios, using specialized CG and special effects app becomes a necessity. ProAnimator is a feature rich 3D design application targeted at motion graphics sector. It is ideal when you want to add some ...

DVDFab DVD Copy - While a lot of computer users are switching from optical media to external and cloud storage services, a section of them still counts on DVD for storage and movie watching. At times it also becomes necessary to copy those DVDs that are getting ...




New Downloads

EarCatch Ringtone Express

EarCatch Ringtone Express is
an advanced solution for
making ringtones from any
sound. It is very easy to
customize ...

Honeyview Image Viewer

Honeyview is very fast image
and archived image viewing
software. It allows viewing of
images within an archive
without ...

ThreeWP Upcoming Posts

Display upcoming posts in a
widget.

POL LiveZilla

This is a module for appear
livezilla on Joomla Base
websites.

Plot 2D/3D Vector with
Arrow

Arrowline 3-D vector plot.

RubikViewer

RubikViewer is a simple GUI
tool that enables rubik's cube
rotation. It is possible to
perform all basic and advanced
...

Matlab 3D vectors to
Paraview (via binary VTK
file)

One of the few weak points in
MATLAB is its low speed when
displaying 3D vector plots

Box Plot with Whiskers
Plotted at Fixed
Percentiles

Normally boxplot plots the
whiskers with a maximum length
based on the distance between
the 25th and 75th percentile.

libConfuse

libConfuse is a configuration
file parser library written in
C.

Vertical Folding Tabs

Vertical folding tabs are
applied with autoscroll GUI
template.

a 3d quasi fuchsian map

a 3d quasi fuchsian map using
3 generators

MATLAB Programming Example
for Agilent's U2600A USB
Modular (DAQ) Digital IO
module

The U2651A module is slotted
into the U2781A USB Chassis.