Displaying 4 results from an estimated 4 matches for "from_index".
Did you mean:
cdrom_index
2006 Mar 25
1
vector conditional modification
dear R users
I need to modify values in a vector, the modification needs to be based on a matrix which define the from_index, to_index and a value.
example:
> x <- c(1, 0, 6, 3, 8, 9, 4, 3, 0)
> m
from to value
1 2 3 5
2 5 7 8
3 9 9 11
>
expected:
1 5 5 3 8 8 8 3 11
insert {R.utils} and append are too expensive and indirect for the task.
thank you...
2008 Dec 15
1
Unicode problem with mb_chars.index
Hello,
I tried the following
str ="ÄÄa__"
assert str.mb_chars.is_utf8?
assert str.is_utf8?
# this is logical
assert_equal 4, str.index("a", 4)
# this is not logical. shouldn''t this be nil !?
assert_equal 2, str.mb_chars.index("a", 4)
Why is the last line failing? And how could I fix this?
Regards,
Peter.
PS: I am using ruby 1.8.6 on linux with rails
2007 Aug 17
0
2 commits - libswfdec/swfdec_as_array.c test/trace
...e (SwfdecAsObject *object,
+ const char *variable, SwfdecAsValue *value, guint flags, gpointer data)
{
ForeachMoveRangeData *fdata = data;
gint32 idx;
@@ -172,12 +186,12 @@ swfdec_as_array_foreach_move_range (Swfd
}
static void
-swfdec_as_array_move_range (SwfdecAsArray *array, gint32 from_index, gint32 num, gint32 to_index)
+swfdec_as_array_move_range (SwfdecAsObject *object, gint32 from_index,
+ gint32 num, gint32 to_index)
{
- SwfdecAsObject *object = SWFDEC_AS_OBJECT (array);
ForeachMoveRangeData fdata = { from_index, num, to_index };
- g_return_if_fail (SWFDEC_IS_AS_ARRAY (...
2007 Aug 17
0
Branch 'vivi' - 9 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_function.h libswfdec/swfdec_as_internal.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_native_function.c
...e (SwfdecAsObject *object,
+ const char *variable, SwfdecAsValue *value, guint flags, gpointer data)
{
ForeachMoveRangeData *fdata = data;
gint32 idx;
@@ -172,12 +186,12 @@ swfdec_as_array_foreach_move_range (Swfd
}
static void
-swfdec_as_array_move_range (SwfdecAsArray *array, gint32 from_index, gint32 num, gint32 to_index)
+swfdec_as_array_move_range (SwfdecAsObject *object, gint32 from_index,
+ gint32 num, gint32 to_index)
{
- SwfdecAsObject *object = SWFDEC_AS_OBJECT (array);
ForeachMoveRangeData fdata = { from_index, num, to_index };
- g_return_if_fail (SWFDEC_IS_AS_ARRAY (...